I have been using the script below to make it so that a random image is displayed everytime the page is refreshed or accessed. It has worked very well, but what i am wondering is does anyone know how to make this code adapt to embeding youtube urls? I have tried several variations without luck. I am not really a coder so most of what i do is trial by error, but i was hoping someone else might be able to point me in the right direction.

Here is the code i am using for the random image generator:

PHP Code:
    <SCRIPT language="Javascript"><!--
   function 
image() { };
   
image = new image();
   
number 0;
   
// imageArray
   
image[number++] = "<img src='http://i74.photobucket.com/albums/i254/cobrarstreetracr/P1010801.jpg' border='0'>"
   
image[number++] = "<img src='Images/DurangoHemi.jpg' border='0'>"
   
   
increment Math.floor(Math.random() * number);  document.write(image[increment]);
   
//-->
   
</SCRIPT>