编辑下面的代码:【加编码】
<html> <body> <p>Countdown to year 3000:</p> <p> <script type="text/vbscript"> millennium=CDate("1/1/3000 00:00:00") document.write("It is " & DateDiff("yyyy", Now(), millennium) & " years to year 3000!<br>") document.write("It is " & DateDiff("m", Now(), millennium) & " months to year 3000!<br>") document.write("It is " & DateDiff("d", Now(), millennium) & " days to year 3000!<br>") document.write("It is " & DateDiff("h", Now(), millennium) & " hours to year 3000!<br>") document.write("It is " & DateDiff("n", Now(), millennium) & " minutes to year 3000!<br>") document.write("It is " & DateDiff("s", Now(), millennium) & " seconds to year 3000!<br>") </script> </p> </body> </html>
结果: 【此窗口】 帮助?
Try it Yourself - © 自强学堂