Thread: Countdown Timer
View Single Post
  #14  
Old 12-06-2011, 09:30 PM
Skyld Skyld is offline
Script-fu
Skyld's Avatar
Join Date: Jan 2002
Location: United Kingdom
Posts: 3,914
Skyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud of
Send a message via AIM to Skyld
Quote:
Originally Posted by Gunderak View Post
I'm not as good as you at it but I'm not as bad as your making me sound.
I don't mean to put you down, but I explained already good reasons why not to put quotemarks around integers, not just for optimisation, but also for clarity. You need to learn from things like this. Doing so will make you a better scripter.

The main reason that I moved the thread out of the code gallery is because I feel that is not a good solution; you are dealing with four variables for a single timestamp, which I don't think is elegant, and not seemingly handling what happens when you start going into negative days. Maybe that introduces potential race conditions later on.

You can make this much more reliable by using a single variable - the number of seconds - and printing the output format using some time formatting functions.
__________________
Skyld
Reply With Quote