Fijate si te sirve algo así:
Código PHP:
<!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=iso-8859-1" />
<title>Documento sin título</title>
<script src="lb/lightbox.js"></script>
<link href="lightbox.css" rel="stylesheet" type="text/css" />
<script>
addLoadEvent(function(){
var idis=['uno','dos'];
var i=0;
window.intervalo=setInterval(function(){showLightbox(document.getElementById(idis[i%(idis.length)]));i++},1000);
var oldClose=hideLightbox;
hideLightbox=function(){
oldClose();
clearInterval(window.intervalo);
}
});
</script>
</head>
<body>
<a id="uno" href="img2/2.jpg" rel="lightbox"><img src="img/2.jpg" width="50" height="50" border="0" /></a><br />
<a id="dos" href="img2/1.jpg" rel="lightbox"><img src="img/1.jpg" width="50" height="50" border="0" /></a>
</body>
</html>