[Javascript] Sorting Problem

liorean liorean at gmail.com
Tue Sep 14 13:02:38 CDT 2004


On Tue, 14 Sep 2004 18:39:51 +0100, Tim Makins <spindrift at oceanfree.net> wrote:
> Well, that's a start. Its not crashing now, but the numerical search results aren't quite right either

Oh, I forgot. Most likely you'll want to parseFloat the a and b
arguments in numSort.

Second, I made a little mistake there:
    (isNaN(b)?Number.POSITIVE_INFINITY:b)
should be
    (isNaN(b)?Number.NEGATIVE_INFINITY:parseFloat(b))
-- 
David "liorean" Andersson
<uri:http://liorean.web-graphics.com/>



More information about the Javascript mailing list