the javascript magic:
<script src=”common/prototype.js” mce_src=”common/prototype.js” type=”text/javascript”></script>
<script src=”common/scriptaculous.js” mce_src=”common/scriptaculous.js” type=”text/javascript”></script>
<script type=”text/javascript” language=”javascript”>
//————LYBILDE LANTERNA MAGICA ————-
var lysbilde = {
startup: function() {
new PeriodicalExecuter(lysbilde.cycle, 4)
},
cycle: function() {
new Effect.Fade(’lysdiv’, {
duration: 1,
fps: 50,
afterFinish: function() {
new Ajax.Updater(’lysdiv’,'managelysbilde.php’, {
asynchronous: true,
onSuccess: function() {
new Effect.Appear(’lysdiv’, {
duration: 1,
fps: 50,
queue:’end’
})
}
})
}
})
}
}
window.onload = lysbilde.startup
</script>
<!– Slutt lanterna magica–>
Let the file managelysbilde.php do the magic.. I use $lys = $_SESSION['lys']; to keep track of the pictures!










