Uhm, it looks like you have a syntax error:
Also, if checking JS functionality, learn to make use of a debugging tool/error console. This would probably have notified you of the error. Firefox has a built-in error console under “Extras > Web developer” or something like that (keyboard shortcut
Cmd/Ctrl+Shift+K). But there’s also the web developer toolbar and Firebug, the most popular add-on. Other browsers like Safari/Chrome or Opera have similar tools built in already.