Random chars for file name? - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23) +--- Thread: Random chars for file name? (/showthread.php?tid=10557) |
Random chars for file name? - El Forum - 08-04-2008 [eluser]stuffradio[/eluser] I am making a public photo sharing type site. It is for a client, and I am trying to be as secure as possible to also prevent hot linking, etc. What would you say is the best method for file naming when they upload the image? Method: The user goes to the site, logs in to their account. They go to the upload page, enters the caption, whether or not it's nsfw (There is a report button if it is not appropriate if it's marked as sfw) When it's uploaded, it gets put in to a folder. The user can also email the photo, and it gets uploaded. End Method; That's a bit of insight as to how it works. What's the best method for randomizing the file names and making sure it doesn't exist? Random chars for file name? - El Forum - 08-04-2008 [eluser]SpooF[/eluser] The fastest and easiest way would go turn on encrypt_name when your load the image library. Code: $config['encrypt_name'] = true; More Info Random chars for file name? - El Forum - 08-04-2008 [eluser]stuffradio[/eluser] I will look, thanks. |