SitePoint Sponsor |
|
User Tag List
Results 1 to 4 of 4
Thread: Best way to fix validation issue
-
May 3, 2009, 15:42 #1
- Join Date
- Oct 2005
- Posts
- 220
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Best way to fix validation issue
Hi,
I get the following error whilst validating a page and would like know the best way around this:
"document type does not allow element "h2" here; missing one of "object", "applet", "map", "iframe", "button", "ins", "del" start-tag"
my html:
Code:<a href="/football-file/"><h2 class="fashion-file-h">my football file</h2></a>
Code:#content .football-file h2.football-file-h { width:122px; height:97px; margin:-16px 0 0 0; padding:0; background:url(../images/myfile.gif) no-repeat; text-indent:-9999px; overflow:hidden;
Code:<a href="/football-file/"><span class="football-file-h">my football file</span></a>
Code:.football-file-h { width:122px; height:97px; margin:-16px 0 0 0; padding:0; background:url(../images/myfile.gif) no-repeat; text-indent:-9999px; overflow:hidden; }
Thanks
-
May 3, 2009, 15:49 #2
- Join Date
- Aug 2000
- Location
- Philadephia, PA
- Posts
- 20,578
- Mentioned
- 1 Post(s)
- Tagged
- 0 Thread(s)
Probably. The <a> element is an inline type, so a block type element like <h2> shouldn't appear inside it.
Try Improvely, your online marketing dashboard.
→ Conversion tracking, click fraud detection, A/B testing and more
-
May 3, 2009, 15:50 #3
-
May 4, 2009, 06:18 #4
- Join Date
- Oct 2005
- Posts
- 220
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Ah of course, thanks for reminding me
Bookmarks