Out of memory at line 29 i simpelt ur-script?!
Hej eksperter...Jeg vil lave mit eget tekst-ur der viser serverens tid... Jeg får bare "Out of memory" på linien
document.getElementById("hour").innerHtml=hour;
i scriptet:
<script type="text/javascript" language="JavaScript">
<!--
var hour = <%= Hour(Now) %>;
var minute = <%= Minute(Now) %>;
var second = <%= Second(Now) %>;
function countSecond(){
second++;
if(second>=60){
second-=60;
minute++;
};
if(minute>=60){
minute-=60;
hour++;
};
if(hour>=24){
hour-=24;
};
document.getElementById("hour").innerHtml=hour;
document.getElementById("minute").innerHtml=minute;
document.getElementById("second").innerHtml=second;
};
function counter(){
countSecond();
setTimeout(1000, counter());
};
-->
</script>
</head>
<body onload="counter()">
Hvad sker der?!
Se det online på www.mrside.dk/test3.asp
Hilsen Mathias