noscript

< html‎ | elements
Jump to: navigation, search

noscript

This article is Ready to Use.


W3C Recommendation

Summary

The HTML NoScript Element (<noscript>) defines a section of html to be inserted if a script type on the page is unsupported or if scripting is currently turned off in the browser.


Overview Table

DOM Interface HTMLElement

The noscript element content will not be visible if scripting is enabled in the browsers. It is used to present different contents and guide the user on what he should be seeing.

The noscript element is not permitted in XML modes.

If you need to display a message to non-scripting user-agents, consider a "loading" message that gets removed by scripting.

Examples

View live exampleYou must disable javascript for this to work.

HTML

<script>
    /* Do stuff with JavaScript */
</script>
<noscript>
For full functionality of this site it is necessary to enable JavaScript. Here are the <a href="http://www.enable-javascript.com/" >instructions how to enable JavaScript in your web browser</a>.
</noscript>

Notes

Browsers that don't support the noscript tag will render the content regardless of whether the javascript is supported


Related specifications

Specification Status Related Changes
HTML 5.1 W3C Working Draft
HTML 5 W3C Recommendation
HTML 4.01 W3C Recommendation

Attribution

This article contains content originally from external sources.

Portions of this content come from the Microsoft Developer Network: [Windows Internet Explorer API reference Article]