js实现团购时间倒计时实例页面

展示

回到相关文章 >>

测试需要,现假设倒计时时间为2050年7月30号中午12点整

0
00
00
00
00
00

代码

JS代码:
<script type="text/javascript" src="../js/timeCountDown.js"></script>
<script type="text/javascript">
var zxx = {
    $: function(id){
        return document.getElementById(id);    
    },
    futureDate: Date.UTC(2050, 6, 30, 12),
    obj: function(){
        return {
            sec: zxx.$("sec"),
            mini: zxx.$("mini"),
            hour: zxx.$("hour"),
            day: zxx.$("day"),
            month: zxx.$("month"),
            year: zxx.$("year")
        }
    }
};
fnTimeCountDown(zxx.futureDate, zxx.obj());
</script>