JS Page Countdown Effect

Source: Internet
Author: User

<!DOCTYPE HTML><HTML>    <Head>        <MetaCharSet= "UTF-8">        <title></title>    </Head>    <Scripttype= "text/javascript">window.onload=function(){            //Countdown function            functionDJs () {varFur_time=NewDate ( .,5, -,Ten, -,0); //set time May 30, 2017        //Create Current Time        varNow_time=NewDate (); //calculate a time difference between two dates        vardiff=fur_time.gettime ()-Now_time.gettime (); //Alert (diff);        varTian=parseint (diff/(24*60*60*1000));//calculate how many days remaining        //gets the number of milliseconds remaining after the calculation of the number of daysdiff=diff%( -* -* -* +); //count hours        varXiaoshi=parseint (diff/(60*60*1000));        //number of milliseconds remaining after the hour is calculateddiff=diff%( -* -* +); //get the number of minutes        varFenzhong=parseint (diff/(60*1000));        //the number of milliseconds after the number of minutes is calculateddiff=diff%( -* +); //Calculate seconds        varMiao=parseint (diff/);        //document.write (' The remaining time also ' +tian+ ' Day ' +xiaoshi+ ' hours ' +fenzhong+ ' minutes ' +miao+ ' seconds ');        varSS=document.getElementById (' time'). getElementsByTagName ('span'); ss[0].innerhtml=tian; ss[1].innerhtml=xiaoshi; ss[2].innerhtml=fenzhong; ss[3].innerhtml=miao;                } DJs (); //Timer for Countdownsetinterval (djs, +); }    </Script>    <Body>        <H2ID= "time">There's still time left.<span>0</span>Days<span>0</span>Hours<span>0</span>Score of<span>0</span>Seconds</H2>    </Body></HTML>

JS Page Countdown Effect

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.