1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

Dynamic Countdown Question

Discussion in 'JavaScript' started by tercede, Feb 9, 2013.

  1. #1
    Would javascript be good for a countdown script?
     
    Last edited: Feb 9, 2013
    tercede, Feb 9, 2013 IP
  2. abyse

    abyse Notable Member

    Messages:
    346
    Likes Received:
    9
    Best Answers:
    1
    Trophy Points:
    245
    #2
    it depends on how you will use it... but if you care about browser compatibility go with a php countdown script, ex: http://www.hotscripts.com/listing/php-countdown/
     
    abyse, Feb 10, 2013 IP
  3. brandon813

    brandon813 Member

    Messages:
    77
    Likes Received:
    2
    Best Answers:
    0
    Trophy Points:
    45
    #3
    Hi there, JavaScript is totally fine for this purpose. In fact, if you look at the source on Ebay auctions, the display of the "time left" for auctions is done with Javascript. Probably a variation on the JQuery countdown code here;

    http://keith-wood.name/countdown.html

    You should not use this code, however, to manage server side operations. Because of the nature of client side code, this should only be used for display and possibly an action after the timeout. Not to trigger an event on the server.
     
    brandon813, Feb 12, 2013 IP