How to display server time count down?

Posted on 2009-02-16
Last Modified: 2013-12-17

I use as the js count down.
I get the datetime from server and run the count down js.

However, different machine shows different count down value.

How can the count down timer run in server side, i.e. compare the system time with the future time.
Question by:techques
    1 Comment
    LVL 5

    Accepted Solution

    Off the top of my head I can think of two options you might consider using.  As your code currently stands I am sure (\based on how you described the issue) that it is all run via Client Side javascript.  If this is the case that is why the user is seeing different times: Javascript runs on the local computer and does not communicate with the server.

    To get the server time you can do one of the two options:
    (1) On the ASP Page Load event pass a javascript variable to the user with the current server time.  Then you can compare that time and the 'local' time in your javascript to define the timezone offset.

    (2) You can use a ASP.Net to create and manage the clock frolm the server side without the use of JavaScript.

    Featured Post

    Gigs: Get Your Project Delivered by an Expert

    Select from freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely and get projects done right.

    Join & Write a Comment

    User art_snob ( encountered strange behavior of Android Web browser on his Mobile Web site. It took a while to find the true cause. It happens so, that the Android Web browser (at least up to OS ver. 2.…
    International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
    Internet Business Fax to Email Made Easy - With eFax Corporate (, you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, fr…
    This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.

    745 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    19 Experts available now in Live!

    Get 1:1 Help Now