If your goal is search engine optimization, then it's probably a good idea to follow the standards and put all your meta tags in <head> . However, as far as browser behavior is concerned, if you put <meta> tags in your <body> , they will still work. I decided to test this using several <meta http-equiv="refresh"/> tags and <title> tags in another standard document.
The results of my tests:
Firefox 18, Firefox 3.6, Firefox Mobile, Chrome 24, Chrome for mobile devices, Opera 12, IE6, IE8, IE10:
- Processed
<meta> tags in the body. - The first
<title> in the document was processed, even if it was in the body. Subsequent <title> tags were ignored. - The earliest meta refresh directive took effect, implying that both are processed.
IE9:
- Same as above, with the exception of all the
<title> tags in the body that were ignored. - IE10 in IE9 standards mode also behaves as follows.
- IE9 in IE8 standards mode behaved the same as IE8, allowing the
<title> tag in tag 1.
So what happens when you use meta tags in the body? By and large, they seem to be working fine. Meta tags are likely to be processed, so if you cannot put them in your head, I will not worry too much.
nullability Jan 24 '13 at 17:01 2013-01-24 17:01
source share