Deal with disabled JavaScript support

From The IT Community
Jump to: navigation, search




JavaScript on web sites can be a very powerful tool, but enabling JavaScript can also lead to security issues. So some people have decided to turn it off.

How do you handle such situations? This is what the <noscript> tag is for.

Here is a example:

<script>
document.write("The IT Community rules!")
</script>
<noscript>Your browser does not support JavaScript!</noscript> 


People who have JavaScript enabled will see the (very true) output "The IT Community rules", while people who have it disabled will get the appropriate notice.


See how you can add a JavaScript menu to your website in the article "Add a JavaScript menu to your web site".



Was this article helpful? Then please donate to keep The IT Community alive...

If you found this article helpful please share it, comment and help others by writing your own article.






Translate this page:




Articles found in the same category:
(max. 20 shown)