RE: [PHP] How do you guys do this?
| From: | PHP Email List | Date: | Sat, 31 Jan 2004 00:41:23 +0000 |
| Subject: | RE: [PHP] How do you guys do this? | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-176423@lists.php.net to get a copy of this message | ||
* Unless more than one person is uploading a picture within the same
second you won't have any problems with duplicate names.
I sure hope that there aren't 2 people uploading breadbox.jpg at the same
second. That'd be too weird! Now maybe if it was a porn site I could see the
same name, tina.jpg, michele.jpg, but again, the same file name on the same
second, what are the odds? <--anyone? :)
-----Original Message-----
From: Chris W. Parker [mailto:cparker@swatgear.com]
Sent: Friday, January 30, 2004 12:23 PM
To: Ryan A; php-general@lists.php.net
Subject: RE: [PHP] How do you guys do this?
Ryan A <mailto:ryan@coinpass.com>
on Friday, January 30, 2004 10:09 AM said:
> common directory (member_pics) so what do you suggest I name the
> pictures? eg:
> username.jpg?
> first_last_name.jpg?
> <random_number>_username.jpg?
how about <timestamp>_originalfilename.jpg?
Someone uploads "breadbox.jpg" you save it as "1010342461_breadbox.jpg".
Or if the traffic will not be insanely high you can just call it
"1010342461.jpg".
hth,
Chris.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php