Upload to Different Folders
Question:
How can I use the extension to upload files in different folders. The extension is on a side with a product (after insert with id (session)). One field is a catecory field (with a number for the catecory). How can I use this number for the upload folder?
Answer:
You can use a dynamic upload folder. For example lets assume that you have a dropdown listbox in your form that allows the users to choose a department. Then you want their files to be saved in "Uploads/<Department>" where <Department> is what they choose.
Then you should just use the following expression as your upload folder:
"Upload/" & UploadFormRequest("Department")
This assumes that your department dropdown listbox is called "Department"
Comments
Upload to Different Folders
Instead of
>>"Upload/" & UploadFormRequest("Department")<<
I've this
Set UploadRequest = CreateObject("Scripting.Dictionary")
BuildUploadRequest RequestBin, """filename""", "file", "1000", "over"
Could you please help
Upload to diffrent folders
"Upload/" & UploadFormRequest("Department").
In the page where the form is or in the IncPureUpload.asp page and where in the code ?
Thank you !
combining these languages is confusing !
how about when there's a dynamic rewritten dropdownlist on the page, for instance files ending up in:
Uploads/<Section>/<Reference>/
resulting in something like: Uploads/Manuals/Websign/WSv1.doc
and / or: Uploads/Designs/OFT/OFTpov204.doc
would i use something like:
"Upload/" & UploadFormRequest("Section") & "/" & UploadFormRequest("Reference")
RE: Upload to different folders
You place this in the "Upload folder" in the main window of the server behavior.
also don't forget to change filename to "prefix with full path".
Dennis
You must me logged in to write a comment.