View Full Version : Which format???

07-13-2004, 01:56 AM
<script language="JavaScript"><!--
var startPageLoad = (new Date()).getTime();
function timeSinceStartPageLoad()
return ((new Date()).getTime() - startPageLoad) / 1000;
document.writeln(" seconds")

Would the above code return the time in seconds?
Or would it return in another format? I assumed it would be seconds?

Pls. Help. Thanx in advance

Radith Silva

07-13-2004, 02:45 AM
Yes. getTime() is in milliseconds so dividing it by 1000 will turn it into seconds.

EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum