Possible issue when using parseInt function
How to force integers not to be octals in PHP applications
He noticed that if you pass a string of '09' the function will attempt to treat the value as an octal (which is a fairly insane thing to have as a default in my opinion) in order to fix this you would change
var test = parseInt('09');
var test = parseInt('09',10);
This will force base 10 to be used instead of octal.