日期:2014-05-16 浏览次数:20345 次
<!doctype html > <html> <head> <title> new document </title> </head> <body> <div id="time"></div> <script type="text/javascript"> window.onload = function(){ var A = 1256056504, B = 1256117187; var t = parseInt((B - A) / 1000); (function(){ document.getElementById("time").innerHTML = t; if(--t >= 0){ setTimeout(arguments.callee, 1000); } })(); } </script> </body> </html>
------解决方案--------------------
显示天数 楼主 可以 用 t 来除以 60 * 60 * 24