Forum Moderators: open

Message Too Old, No Replies

Saving Files with Random Names

         

traeanthony

6:25 am on Nov 14, 2005 (gmt 0)

10+ Year Member



I have a form that saves a txt file to a folder on the server. However, I need the form to save each submuittal as an individual file. Is there anyway I can generate a random file name when the form is subitted?

Jimmy Turnip

9:31 am on Nov 14, 2005 (gmt 0)

10+ Year Member



You could save each name as a guid, or use the date now (with seconds) and remove all the illegal characters like ':', '/', and white space.

traeanthony

7:14 pm on Nov 14, 2005 (gmt 0)

10+ Year Member



Great Idea! I never would have thought of that!

Thank you!

BradleyT

9:42 pm on Nov 14, 2005 (gmt 0)

10+ Year Member



We use guid names for uploaded images on almost every site we do. Works great.