Uploaded file names

n3 n3eight 27 Jul, 2009
Hi, is there any way to rename the uploaded files based on the value of one of the form inputs? I intend to use the form for students to submit assignments, and it would be useful if the file name would let me know which assignment and which student the file belonged to. Thanks
Gr GreyHead 27 Jul, 2009
Hi n3eight,

I don't think that you can do this automatically (I'll go and check the code to make sure).

You can do it by using code in the OnSubmit box to rename the file. There was a thread on this several months ago where I think we worked out how to rename a file and move it into a 'student' folder.

Bob
Max_admin Max_admin 27 Jul, 2009
Hi n3eight,

in the latest release ONLY there is a new "file name" formula field under the uploads tab, you may use it to change the file name, you need to put a good PHP or it will break the whole submit process!

Cheers
Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
Gr GreyHead 27 Jul, 2009
Hi Max,

To save me looking - is the $posted array available for the file name PHP?

Bob
This topic is locked and no more replies can be posted.