Script

Hola amigos he estoy intentando hacer el post ROTACION PARA IMAGENES relacionado con un script, pero no me funciona.
Aquí les dejo mi codigo para que me ayudeis.

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title>OrganicUtopia Home Page</title>


<style type="text/css">
body {
font-family: "Lucida Sans Unicode", "Lucida Grande", sans-serif;
font-size: small;
color: #333;
background-color: #739112;
text-align: center;
}

#container {
background-color: #FFF;
width: 770px;
height: 850px;
margin-right: auto;
margin-left: auto;
position: relative;
text-align: left;
background-image: url(images/veggie_background.jpg);
background-repeat: no-repeat;

}


#header {
height:80px;
z-index:1;
background-color: #9fcc41;
background-image: url(images/veggies.jpg);
background-repeat: no-repeat;
background-position: right;
}


#header img {
margin-top: 20px;
margin-left: 15px;
}

dl {
color: #000;
font-size: medium;
margin-left: 15px;
font-family: Georgia, "Times New Roman", Times, serif;
font-weight: bold;
}

dd {
font-size: small;
margin-bottom: 10px;
font-weight: normal;
margin-right: 10px;
font-family: "Lucida Sans Unicode", "Lucida Grande", sans-serif;
margin-left: 5px;
}



#galeria {
position:absolute;
width:350px;
height:270px;
z-index:1;
background-color: #FFFF00;
}
</style>


<script language="javascript">
step=0;
function autoImgFlip() {
if (step < 3) {step++;}
else {step=0;}
if (step==0)
{a.src="plantilla/imagenuno.jpg";}
if (step==1)
{a.src="plantilla/imagendos.jpg";}
setTimeout("autoImgFlip()", 3000);
if (step==2)
{a.src="plantilla/imagentres.jpg";}
if (step==3)
{a.src="plantilla/imagencuatro.jpg";}

}
</script>




</head>

<body onLoad="autoImgFlip();">




<div id="container">
<div id="header"><img src="images/ou_logo.gif" width="210" height="41" /></div>

<div id="galeria">

[contenido no disponible]


</div>
</div>
</body>
</html>

Gracias y perdonar mi ignorancia.