TechNomad

Users' Comments
Login with Facebook
Login with Google
Login with FourSquare
Login with Windows Live
HTML5 Powered with CSS3 and Semantics

parseInt

19:12

I've discovered something a bit annoying about JavaScript's parseInt() function just now: A string with a leading zero is not parsed using base 10... eg, "010" becomes 8 and "08" becomes 0, but "04" is 4, so it appears to have been using base 8. Well, I just had to add a second parameter to each function call so that it would use base 10 and I'm done.
<< 2 Feb 2008
10 Feb 2008 >>
7 Feb 2008