如何制作一个倒计时的程序?

 更新时间:2006年11月16日 00:00:00   作者:  
(福利推荐:【腾讯云】服务器最新限时优惠活动,云服务器1核2G仅99元/年、2核4G仅768元/3年,立即抢购>>>:9i0i.cn/qcloud

(福利推荐:你还在原价购买阿里云服务器?现在阿里云0.8折限时抢购活动来啦!4核8G企业云服务器仅2998元/3年,立即抢购>>>:9i0i.cn/aliyun

<%
CountdownDate = #1/1/2008 00:00:00AM#
If Date >= CountdownDate Then
    Response.Write "2008 
北京"
    Response.End
End If

theDate    = Now
DaysLeft    = DateDiff("d",theDate,CountdownDate) - 1
theDate    = DateAdd("d",DaysLeft,theDate)
HoursLeft  = DateDiff("h",theDate,CountdownDate) - 1
theDate    = DateAdd("h",HoursLeft,theDate)
MinutesLeft = DateDiff("n",theDate,CountdownDate) - 1
theDate    = DateAdd("n",MinutesLeft,theDate)
SecondsLeft = DateDiff("s",theDate,CountdownDate) - 1
%>

<html>
<body>
现在时间: <%= Now %>
<p>
距离2008年还有 <%= DaysLeft%><%= HoursLeft %> 小时<%= MinutesLeft %> <%= SecondsLeft %>.走得最急的,都是最美的时光.
</body></html>

[1]

相关文章

最新评论


http://www.vxiaotou.com