I'm with sunfighter, you should clean up your code to both help and now and to prevent more issues in the future. Also, all browsers do different things (*cough* IE *cough*), so you should consider making separate bits of code for each browser. That would solve the problem of cross-browser compatibility. If this is too much of a time investment for you, just consider the fact that each browser (FF, IE, GC, O, etc.) has very specific different rules for how things are displayed. To prevent a multitude of errors, you should have everything validate and be cross-browser compatible.
Hope this helps.
PS. I would suggest separate code for mobile operating systems as well.
Last edited by Nerevarine; 01-09-2013 at 04:33 PM..
Reason: Added the PS