Newb html question

jb2008

Senior Member
Joined
Jul 15, 2010
Messages
1,158
Reaction score
976
I want to add <meta name="robots" content="noarchive">

to my header, but it already has the following:

<meta name="robots" content="follow, all" />

Do I just take a new line and paste in <meta name="robots" content="noarchive">

or do I add , noarchive after all ?

Also, what is the difference between the <....... > in the noarchive line, and the <........../> in the follow, all line?

Thanks
 
HTML:
<meta name="robots" content="index, follow, noarchive">

And the slash at the end is useless.

Beny
 
Last edited:
slash at the end is not useless. if your doctype is XHTML as opposed to HTML you should close the tag with a /> and make sure you have a space before the slash.
 
HTML:
<meta name="robots" content="index, follow, noarchive"/>
 
You can use the slash, but it's not important.
With and without are W3C valid (in HTML5, anyway...).

In xHTML it's recommended to put the slash at the end (for self-closing elements like <img>, <a>, <input>, ...).

Beny
 
Last edited:
Hey guys,

thanks so much for your swift answers & productive discussion. I couldn't find the answer anywhere as to the difference.

My site is wordpress, if it helps. Is it XHTML or HTML? (of course I know wordpress is php not static but the page produced)
 
Is it XHTML or HTML?

Check the DOCTYPE in your page header.
(View/Source)
 
the slash is only really important if you're doctype is xhtml and if you're worried about your code validating. no reason not to add the slash though.
 
Doctype is XHTML 1.0 Transitional .

So I'm gathering:

No slash for HTML
Slash for XHTML

And what is the difference between "follow, all" and "index, follow" ? Isn't it obvious that you want the robot to index your stuff and follow the links unless you put noindex and nofollow in there or something? And what is the "all" command all about? I tried to read about it on this page: http://www.csgnetwork.com/robots.html but it still doesn't make much sense to me. Do I even need the index,follow in there since it's the default?
 
Last edited:
Back
Top