Results 1 to 7 of 7

Thread: Help with Countdown Script

  1. #1
    Join Date
    Mar 2010
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Question Help with Countdown Script

    Hi,

    I am a big novice when it comes to Script, and I copied and pasted the script for the Universal Countdown http://www.dynamicdrive.com/dynamici...lcountdown.htm however, it just displayed lots of Strange things including NAN for the Days, Mins Hours etc. It also displayed a message saying the local time was invalid, and the date must be in the future - which it was.

    Can anyone please help. Much appreciated.

    Mark (Helix242)

  2. #2
    Join Date
    May 2007
    Location
    Boston,ma
    Posts
    2,127
    Thanks
    173
    Thanked 207 Times in 205 Posts

    Default

    Link to your site.
    Corrections to my coding/thoughts welcome.

  3. #3
    Join Date
    Aug 2004
    Posts
    10,143
    Thanks
    3
    Thanked 1,008 Times in 993 Posts
    Blog Entries
    16

    Default

    Please post a link to the page on your site that contains the problematic script so we can check it out.
    DD Admin

  4. #4
    Join Date
    Mar 2010
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Link

    Hi,

    Heree is the link.

    Many thanks in advance!

    http://www.darkformproductions.com/index.html

    I am using Vista Basic

  5. #5
    Join Date
    Aug 2004
    Posts
    10,143
    Thanks
    3
    Thanked 1,008 Times in 993 Posts
    Blog Entries
    16

    Default

    The problem is that your page doesn't seem to be a PHP page, or the page type you've set inside the script when calling it:
    Code:
    var launchdate=new cdLocalTime("cdcontainer", "server-php", 0, "April 23, 2010 15:53:00", "debugmode")
    You can either try renaming your page so it ends with .php, or use a different server side language for the script to get the server date/time using, such as SSI. In this case, your page most likely would need to be renamed with the .shtml extension.
    DD Admin

  6. #6
    Join Date
    Mar 2010
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Hi,

    Many thanks! I have saved as .shtml and it does work, but the style setting do not seem to be correct. Can you please help. Many thanks

    http://www.darkformproductions.com/Contact%20Us.shtml

  7. #7
    Join Date
    Aug 2004
    Posts
    10,143
    Thanks
    3
    Thanked 1,008 Times in 993 Posts
    Blog Entries
    16

    Default

    What's wrong with the style? If you're referring to the fact that it doesn't have that "LCD" style like in the DD demo, you'll need to add the following CSS to your page:

    Code:
    <style style="text/css">
    
    .lcdstyle{ /*Example CSS to create LCD countdown look*/
    background-color:black;
    color:lime;
    font: bold 18px MS Sans Serif;
    padding: 3px;
    }
    
    .lcdstyle sup{ /*Example CSS to create LCD countdown look*/
    font-size: 80%
    }
    
    </style>
    And also, add the following CSS class inside your timer DIV tag:

    Code:
    <div id="cdcontainer" class="lcdstyle"></div>
    DD Admin

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •