Rename the file each time it is saved

This script that I’m using, on a web page, allows a web page visitor to record a video, via his webcam. However, the recording is given the same file name each time (Video), therefore each new recording replaces the previous stored one.

How can I add code that will give each recording a unique file name - so that all recordings are saved/stored (instead of replaced)?

<!DOCTYPE html PUBLIC “-//W3C//DTD XHTML 1.0 Strict//EN” “”>
<html xmlns=“” lang=“en” xml:lang=“en”>
<meta http-equiv=“Content-Type” content=“text/html; charset=utf-8” />
<script type=“text/javascript” src=“js/swfobject.js”></script>

&lt;body bgcolor="#ffffff"&gt;
	&lt;div id="recorder"&gt;&lt;/div&gt;

          &lt;script type="text/javascript"&gt;
           // &lt;![CDATA[
           var so = new SWFObject("recorder.swf", "recorder", "620", "470", "9", "#000000");
           // ]]&gt;


I wrote an upload script on mywebsite… i had a similar problem… i solved it by:

renamed the uploaded file to

$x = md5(1,1000);
its almost impossible to have the same md5 value specially when adding the filename.

you might wanna change the name to video(randomnumber)_somethingyouwant_videoname

might be handy

Thanks so much for your reply.
The code I posted is not something I created.
So, I’m not a programmer.
I greatly appreciate your solution, however, I’m not clear on how or where to use it with the code I posted.
Any additional clarification would be welcomed.
Thanks again.