[Greasemonkey] Greasemonkey 0.3

Edward Lee edilee at gmail.com
Mon Apr 11 03:59:07 EDT 2005


Any reasoning behind the characters and number of characters for the
new file name? Mostly wondering about the toLower. Oh and probably
could just use \W dropping the caseless matching, but maybe your way
is more efficient (reduces quite a few cases..)?

var base = script.name.replace(/[^A-Z0-9_]/gi, "").toLowerCase();
base = base.substring(0, 24);



-- 
Ed


More information about the Greasemonkey mailing list