Get foldername when uploading

Any tips and tricks that has to with the ADDT that doesn't fit into one of the other categories
mrhankey
Posts: 45
Joined: 2010-07-31 18:20

Get foldername when uploading

Post by mrhankey » 2011-07-16 20:29

hi,

i have created a virualt folder system where all files are uploaded into the one directory however they files once uploaded at first can be moved to a different folder name.

this is fine however what the user has to do is upload the document first then move it using and update record to a desired folder name.

my question is, can i set the upload behavior and use $get foldername from the form to upload the file into the virtual folder in table?

how can i have this work alongside each other?

thanks again

User avatar
Fred
Site Admin
Posts: 491
Joined: 2010-02-15 12:10
Location: Armagh, Northern Ireland
Contact:

Re: Get foldername when uploading

Post by Fred » 2011-07-24 16:18

Sure you should be able to do that.

When the user moves the file to a different virtual folder using the update form, do you rename the filename to say "folder_filename"?

If so then you should be able to use the "none: rename rule" option in the upload SB

mrhankey
Posts: 45
Joined: 2010-07-31 18:20

Re: Get foldername when uploading

Post by mrhankey » 2011-07-25 19:56

hi Fred,

thnks for your help.

what my idea was that when doing the upload i could get the folder name it was going into from a form on the page. i am unsure how i can do this as all i can do is set naming rules for the filename not the folders they will be "going into" virtually.

other thing is how can i modify the redirect of the upload behaviour manually?

as it automatically refreshes the page your on instead.

cheers

User avatar
Fred
Site Admin
Posts: 491
Joined: 2010-02-15 12:10
Location: Armagh, Northern Ireland
Contact:

Re: Get foldername when uploading

Post by Fred » 2011-07-26 12:42

To access a POST variable in a SB you would use the following format;
{POST.field_name}

Where field_name is the id of the field

mrhankey
Posts: 45
Joined: 2010-07-31 18:20

Re: Get foldername when uploading

Post by mrhankey » 2011-07-28 12:36

thanks fred, do you know how i can edit the upload redirect to go to a tab rather than just the page it is on?

cheers

Post Reply