Forum Moderators: open

Message Too Old, No Replies

Code not valid at W3C

My code shows as not valid but very similiar page does show vaild.

         

sendsley

3:38 pm on Jul 9, 2007 (gmt 0)

10+ Year Member



Checking my pages at W3C.org for valid xhtml code I'm getting some confusing results that I don't understand. Hoping for some assistance.

Pages are <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"

For the page <snip> I get 10 errors that reference tags not allowed or not closed but they are closed and should be allowed I believe.

For the page <snip>/Templates/2007WeeklyNFLPages.dwt.php which has the same code for the header section of the page it comes back as valid at W3C.org checker.

So, what's wrong with the page?

And does it matter. I'd like to have compliant code but is it vital? And should I be using this doctype?

Thanks in advance!

[edited by: encyclo at 4:16 pm (utc) on July 9, 2007]
[edit reason] See Guide to Posting Code [webmasterworld.com] [/edit]

bcolflesh

3:56 pm on Jul 9, 2007 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Don't post your URL here - that said:

line 24: missing </a> tag.

Line 26: same thing and so on with missing </p> tags later on.

fix all those missing tags and revalidate.

sendsley

4:08 pm on Jul 9, 2007 (gmt 0)

10+ Year Member



Sorry about the URL, I thought I was following guidelines by not posting http: and www

Thanks, but looking at the code on the W3C results page it shows the close tags being there....

In an effort to not post URLs I won't show the example but if you view my URL at W3C.org and show code you'll see that the so called missing tags are there....

Thanks

bcolflesh

4:10 pm on Jul 9, 2007 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



I did - it's not there - that's why you getting an error.

sendsley

4:26 pm on Jul 9, 2007 (gmt 0)

10+ Year Member



Again thank you. But I'm clearly missing something.

Here is the line 24 error

# Error Line 24, column 86: end tag for "a" omitted, but OMITTAG NO was specified .

...ll-picks.php">Football Picks</a></div>

You may have neglected to close an element, or perhaps you meant to "self-close" an element, that is, ending it with "/>" instead of ">".

&#9993;
# Info Line 23, column 17: start tag was here .

<div class="nav"><a href="......example.com/free-football-picks.php"><i

Here is line 24 from my source code (sorry about the URL but I see no choice):
<a href="......example.com/free-football-picks.php">Football Picks</a></div>

The </a> tag IS there, isn't it? Is it in the wrong place?

Thanks

[edited by: jatar_k at 4:51 pm (utc) on July 9, 2007]
[edit reason] please use example.com [/edit]

bcolflesh

4:31 pm on Jul 9, 2007 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



The end tags are missing from places earlier in the code - the validator picks up the error on another line, because it finds another start tag before the other one was closed - look a line or two above all your errors.

sendsley

4:34 pm on Jul 9, 2007 (gmt 0)

10+ Year Member



I think I may have found the </a> issue, I have an a href to the img and to the text. Each has an a href but the img is not closed.

I was focused on the single line of code that was the text link, which was correct.

Thanks