The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums JavaScript onClick handler not working Re: onClick handler not working


Sorry, it’s working for me. Check your document type and browser. Make sure there aren’t any JavaScript errors anywhere. I tested in Chrome using HTML 4.01 strict.

I’m not sure how exactly you plan to use this, but instead of using visibility, you might want to try “display: none” and “display: block” instead. But, then again, maybe not.

Also, I highly recommend using jQuery for this kind of thing, but if you’re posted on here before you’ve probably been given this line before. Good luck.