osCommerce Tweak (Part I): Renaming Uploaded Images
osCommerce is a fully featured open-source (free) online shop which can be downloaded from www.oscommerce.com. While it’s abundant with features there are a few tweaks that should be done before launching your e-commerce website. This first part describes how to automatically rename all uploaded images to prevent images being overwritten.
When you upload a product, category, or manufacturer image you will notice that the filename remains the same. This can lead to problems when uploading a different image with the same name, as this image will overwrite the previous one - therefore we must make the images unique.
This is done in one very quick and easy step. Firstly, open the following file in your text-based editor:
/admin/includes/classes/upload.php
Locate the following code (around line 70):
$this->set_filename($file['name']);
Replace with the following code:
$this->set_filename(time().$file['name']);
Upload this file again and add an image from the admin area. You will now see a 10-digit number appended to the start of the image. This number is a UNIX timestamp and is the number of seconds since 1970. This means that every image you upload will be unique.

Thanks. For this was looking for a way to randomise (randomize?) filenames on upload! Lifesaver. Cheers
great tip, thank you!
Simple but effective solution