NetTalk Central
Toggle navigation
Login
Register
×
Welcome,Guest
1 Hour
1 Day
1 Week
1 Month
Forever
Login with username, password and session length
NetTalk Central
»
NetTalk Web Server
»
Web Server - Ask For Help
»
Dynamic folder names for file upload
« previous
next »
Print
Pages: [
1
]
Author
Topic: Dynamic folder names for file upload (Read 3876 times)
astahl
Sr. Member
Posts: 308
Dynamic folder names for file upload
«
on:
August 09, 2010, 06:24:38 AM »
In my forms I have a unique record number(Job Number) which I want to use as the folder name ie "uploads\123456\".
How do I get that number from a webform to the webhandler when I press the save button, so I can use it?
Ashley Stahl
Logged
Alberto
Hero Member
Posts: 1873
Re: Dynamic folder names for file upload
«
Reply #1 on:
August 09, 2010, 12:04:16 PM »
Hi Ashley,
WebHandler proc, RenameFile, after the parent call.
See attached image.
The code is something like:
self.site.UploadsPath = clip(self.site.WebFolderPath) & '\uploads\MyNewFolder'
[attachment deleted by admin]
Logged
-----------
Regards
Alberto
kevin plummer
Hero Member
Posts: 1195
Re: Dynamic folder names for file upload
«
Reply #2 on:
August 09, 2010, 02:43:31 PM »
How do I get that number from a webform to the webhandler when I press the save button, so I can use it?
> in your form add it to the session Q eg p_web.ssv('JobNumberFolder',job:jobnumber)
> in the web handler self.site.UploadsPath = clip(self.site.WebFolderPath) & self.gsv('JobNumberFolder')
Logged
astahl
Sr. Member
Posts: 308
Re: Dynamic folder names for file upload
«
Reply #3 on:
August 10, 2010, 05:14:26 AM »
Thanks Guys!!!! That did it, works like a charm.
ashley Stahl
Logged
Print
Pages: [
1
]
« previous
next »
NetTalk Central
»
NetTalk Web Server
»
Web Server - Ask For Help
»
Dynamic folder names for file upload