[thelist] Netscape and Opera are slower than IE with JS

Plunkett, Matt thelist at lists.evolt.org
Mon Sep 23 13:42:00 2002


Syed,

Just a few quick thoughts..didn't look at this very carefully.

Your vars for title and urls don't have a comment before the length > 100.

You might want to consider allocating the size of your arrays before hand.
This often speeds up the javascript somewhat.

var keys = new Array(200); //keywords         length>100

Instead of admonishing your users not to input more than one space...why not
do your split on one or more spaces?

given = given.split(/\s+/);

You could also throw the plus sign in there if you wanted.

given = given.split(/[\s\+]+/);

HTH,
Matt