?
Solved

<NOSCRIPT> at top of page?

Posted on 2006-04-17
8
Medium Priority
?
205 Views
Last Modified: 2006-11-18
Is the <NOSCRIPT> tag valid at the top of a page?  If so, exactly where after Body tag...
What are drawbacks to have it there, instead of the bottom, where it usually occurs?

Also, is an <image> tag description seen as text by a search engine, or ignored?
Please contribute to my question below, total 500 points for answer.  Thank you.
http://www.experts-exchange.com/Web/Online_Marketing/Q_21816615.html
0
Comment
Question by:scrathcyboy
  • 4
  • 4
8 Comments
 
LVL 14

Expert Comment

by:nltech
ID: 16472271
<NOSCRIPT> anywhere outside of the <BODY> tag isn't valid, and won't validate in <BODY> unless it's properly closed.

putting it after </HTML> is a trick usually used to try to stop free web hosts from sticking scripted ads on your site..

the ones who have gotten smart stick all kinds of closing tags after </HTML> to close anything that may have been used, like:

</object></layer></div></span></style></noscript></table></script></applet>

which is used by geocities.

sticking it at the top won't help with that either because when a site adds stuff to the top, it will be before it anyway.

0
 
LVL 44

Author Comment

by:scrathcyboy
ID: 16472599
"exactly where after Body tag"
To restate, at the top AFTER (not outside) the body tag, where?
0
 
LVL 14

Expert Comment

by:nltech
ID: 16472690
in order to validate your code, it belongs between <body> and </body> and it must be properly closed:

<body>
<noscript>
Some stuff to hide from script-capable browsers.
</noscript>
</body>

it is normally used to follow a script in order to provide alternate content for people who don't have javascript or have it disabled.

see also: http://www.w3.org/TR/REC-html40/interact/scripts.html#h-18.3.1
0
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 44

Author Comment

by:scrathcyboy
ID: 16472869
apparently you are not understanding question?  I know noscript is within body tag, we all know that, I was asking if it can be moved to the TOP of the body section, because it normally appears at the bottom.  Then I ask what are negative impacts to moving it before main HTML code of page, this is what Q asks.
0
 
LVL 44

Author Comment

by:scrathcyboy
ID: 16472968
BTW you will notice the link you include says NOTHING about position of <noscript> tag in body, this is exactly why I ask, w3 docs are very deficient in good intelligent information other than very basic stuff.
0
 
LVL 14

Expert Comment

by:nltech
ID: 16473119
it can go wherever you want it to so long as its inside the body of your html document. anywhere. it could be the very first thing after <body> or the very last thing right before </body> , or somewhere in between. it doesn't matter.

what does matter is that it must be properly closed if you want your code to validate.
0
 
LVL 44

Author Comment

by:scrathcyboy
ID: 16512621
Sorry I dont think this input is correct, never seen noscript tag anywhere but at end of page, this is important not to impair indexing of site, unless other relevant input,  I should remove with no points.

This is the question I need answered -
'If so, exactly where after Body tag...What are drawbacks to have it there, instead of the bottom, where it usually occurs?"

as I asked in original question.
0
 
LVL 14

Accepted Solution

by:
nltech earned 1000 total points
ID: 16514714
<noscript> when used properly and as intended, be can be *anywhere* inside the <body> and </body> tags.

it's function is to provide alternate content for non-script enabled browsers, and usually follows a <script> tag and script, such as:

<script type="text/javascript">
     <!--
     some script here
     -->
</script>
<noscript>
     <p>Sorry you need javascript to see this</p>
</noscript>

in this context, it can go anywhere in the body of an html page, as the tag is properly closed and it doesn't interfere with anything else on the page.


if you're not "following the rules" and not closing the tag properly with </noscript> then you can stick it wherever you want so long as it's AFTER any content you do want displayed to script-capable browsers.


note that your code will not validate unless <noscript> is a) properly closed with </noscript> and b) between <body> and </body>.
0

Featured Post

Upgrade your Question Security!

Add Premium security features to your question to ensure its privacy or anonymity. Learn more about your ability to control Question Security today.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article discusses how to create an extensible mechanism for linked drop downs.
Today, the web development industry is booming, and many people consider it to be their vocation. The question you may be asking yourself is – how do I become a web developer?
In this tutorial viewers will learn how to code links for mobile sites that, once clicked, send a call or text to a specified number. For a telephone link (once clicked, calls a number), begin with a normal "<a href=" link tag. For the href, specify…
In this tutorial viewers will learn how to embed an audio file in a webpage using HTML5. Ensure your DOCTYPE declaration is set to HTML5: : The declaration should display (CODE) HTML5 is supported by the most recent versions of all major browsers…
Suggested Courses

807 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question