I'm having a bit of a problem with this. I'm trying to put a clock that uses UTC/ZULU/GMT time no matter what the user machine's timezone is set to. I have no idea when it comes to javascript so I am attempting to use this free script:
<script language="JavaScript">
function tS(){
x=newDate(
tN().getUTCFullYear(),tN().getUTCMonth(),tN().getUTCDate(),
tN().getUTCHours(),tN().getUTCMinutes(),tN().getUTCSeconds()
);
x.setTime(x.getTime());
return x;
}
function tN(){ return new Date(); }
function lZ(x){ return (x>9)?x:'0'+x; }
function dT(){
if(fr==0){
fr=1; document.write('<font size=4 face=open_sanslight><b>
<span id="tP">'+eval(oT)+'</span></b></font>');
}
document.getElementById('tP').innerHTML=eval(oT); setTimeout('dT()',1000);
}
function y4(x){ return (x<500)?x+1900:x; }
var mN=new
Array('Jan','Feb','Mar','Apr','May','Jun','Jul','Aug','Sep','Oct','Nov','Dec'),
fr=0,oT="lZ(tS().getHours())+':'+lZ(tS().getMinutes())+' '+'<'+'b'+'r'+'>
'+' '+mN[tS().getMonth()]+' '+tS().getDate()+','+' '+y4(tS().getYear())";
</script>
This displays UTC time perfectly for me because I am on British Summer Time, however if I set my clock one hour forward then the web page clock gets set one hour forward too. I have no idea how I could correct this and so I was wondering if anyone could show me how to do it.
Thanks everyone, I appreciate the help.