[thelist] output value

Morgan Kelsey morgan at morgankelsey.com
Sat Jan 25 03:29:01 CST 2003


scott,

>----- Original Message -----
> From: "Scott Brady" <evolt at scottbrady.net>
>
> Morgan (and thelist in general).
>
> I'd like to apologize for my defensive post yesterday
> regarding the use of Evaluate() vs. Form[] notation.  I was in
> a fairly pissy mood and got hypersensitive about the use of
> the word "wrong".
>
> What was I pissy about? See my tip for the source of my
 > frustration.
>

hey, don't worry about it. yesterday, i told someone if they didn't shut-up i was
going to stick a pen in their eye.


> <tip author="Scott Brady" type="javascript">
> If you're dealing with number strings with leading 0's,
> Javascript interprets the number as a base-8 (octal) number
> (if it starts with "0x" it interprets it as a hexadecimal number).
>
> [snip]
>
> So, to get around this, I had to trim any leading 0's.
> </tip>

alternatively, you could simply set the mathematical base with the second argument
of parseInt, like so:

parseInt(09,10)




nagrom
http://morgankelsey.com/





More information about the thelist mailing list