Webmaster Forum


Go Back   Webmaster Forum > Web Development > Web Design Lobby
Register FAQ Members List Calendar Search Today's Posts Mark Forums Read

Web Design Lobby Forum for general web design issues not specific to scripting or graphics.

Directory Submission Service   ClickBooth Network   V7N Directory

Reply
 
LinkBack Thread Tools Display Modes
Old 02-10-2007, 01:00 PM   #1 (permalink)
Inactive
 
sachi's Avatar
 
Join Date: 07-12-06
Posts: 30
iTrader: 0 / 0%
Latest Blog:
None

sachi is liked by somebodysachi is liked by somebodysachi is liked by somebody
Help me understand Validation.

Validate, validate, validate. That is what they always say before asking for help with CSS. I understand that. But what happens if you don't know to how to make heads or tails of your validation errors?

To cut to the chase, this is site that I'm working on.

There are a couple of issues that I'm trying to understand when it comes to validation.

First, I get errors about me missing a head or start tag. Here is an example of my site;
Code:
document type does not allow element "meta" here; assuming missing "head" start-tag . <meta name='robots' content='noindex,nofollow' />
Or I seem to missing a ul, ol, or menu start tag such as this;

Code:
document type does not allow element "li" here; missing one of "ul", "ol", "menu", "dir" start-tag . <li> <li><a href='#
But when I check my html, I know that I don't have two li li tags like that, so I don't understand how the validator came to that conclusion?

I have 12 validating errors. 10 of them are because of improper nesting with my lists.

and then third error I get is ;
Code:
end tag for element "a" which is not open . ...rmation <a href="/sitemap/" />Sitemap</a></p>
I don't get it. Isn't the "/a" supposed to be there?

Help me make sense of validation so that I can please the validating gods and make this site xhtml 1.0 valid!

BTW- if there is online resource that helps give examples of how to validate xhtml elements in a non-techie way, then that would be appreciated.

Last edited by sachi : 02-10-2007 at 01:03 PM.
sachi is offline  
Add Post to del.icio.us
Reply With Quote
Sponsored Links
SEO Hosting by HostGator  Advertise Here  Buy Blog Links
Old 02-10-2007, 03:50 PM   #2 (permalink)
v7n Mentor
 
Join Date: 07-24-06
Posts: 688
iTrader: 1 / 100%
Latest Blog:
None

nasty.web is just really nicenasty.web is just really nicenasty.web is just really nicenasty.web is just really nicenasty.web is just really nicenasty.web is just really nicenasty.web is just really nicenasty.web is just really nicenasty.web is just really nicenasty.web is just really nice
1. you miss the <head> tag. I've found the closing tag </head>, but you've not opened it.
2. your haven't closed the first <li>
3. the a tag cannot be closed like that<a href="/sitemap/" />

The rules: all tags must be closed. Some are unpaired tags, that have no closing elements - they end with />. Other tags open and close in pairs : <li> ... </li>, etc
nasty.web is online now  
Add Post to del.icio.us
Reply With Quote
Old 02-10-2007, 06:29 PM   #3 (permalink)
Inactive
 
sachi's Avatar
 
Join Date: 07-12-06
Posts: 30
iTrader: 0 / 0%
Latest Blog:
None

sachi is liked by somebodysachi is liked by somebodysachi is liked by somebody
Thanks for helping. #1 and #3 makes more sense now. However, after messing around with #2, I am still lost. This is what my code looks like for the sidebar. Can you tell me where the li tag is missing here?

I am using dreamweaver and I assume it automatically closes any tags that I may have been missing.

Also, I got this list from what the Wordpress documentation said about how to style nested lists here. Apparently, I am still not making the connection with this.

Code:
<ul> <li><h2><a href="#">Back to Homepage</a></h2></li> <li><h2>Last Five Entries</h2> <ul> <li><?php wp_get_archives('type=postbypost&limit=5'); ?></li> </ul></li> <li><h2>Categories</h2> <ul> <li><?php wp_list_cats('sort_column=id&optioncount=0&children=0&exclude='); ?></li> </ul></li> <li><h2>Archives</h2> <ul> <li><?php wp_get_archives('type=monthly'); ?></li> </ul></li> </ul>

Last edited by sachi : 02-10-2007 at 06:32 PM.
sachi is offline  
Add Post to del.icio.us
Reply With Quote
Old 02-11-2007, 09:51 AM   #4 (permalink)
Inactive
 
Join Date: 02-05-07
Location: Oxford, UK
Posts: 6
iTrader: 0 / 0%
Latest Blog:
None

Lorissa is liked by many
It looks like you have an extra <li> encapsulating the nested list. Perhaps WP is inserting this? When I view source, I see this:

Code:
<li><h2><a href="#">Back to Homepage</a></h2></li> <li><h2>Last Five Entries</h2> <ul> <li> <li><a href='http://sachitesting.com/2007/01/25/trackbacking-another-comment/' title='Trackbacking another comment'>Trackbacking another comment</a></li> <li><a href='http://sachitesting.com/2007/01/25/another-blog-entry-to-test/' title='Another blog entry to test'>Another blog entry to test</a></li> <li><a href='http://sachitesting.com/2006/11/07/just-testing-this-out/' title='just testing this out!'>just testing this out!</a></li> </li> </ul> </li>
It occurs on all 3 lists - Last Five Entries, Categories and Archives. Remove that extra encapsulating <li> and </li> and you should be set.

I hope this helps!

Cheers,
Lorissa
Lorissa is offline  
Add Post to del.icio.us
Reply With Quote
Old 02-11-2007, 02:32 PM   #5 (permalink)
Inactive
 
sachi's Avatar
 
Join Date: 07-12-06
Posts: 30
iTrader: 0 / 0%
Latest Blog:
None

sachi is liked by somebodysachi is liked by somebodysachi is liked by somebody
Thanks Lorissa. I've sinced removed the <li></li> tags in my sidebar.php file before uploading and the site validates fine.

So my question is was I wrong to put <li> tags there to begin with as it relates to CSS nested lists? Or was it a WP issue that I had to accommodate for?
sachi is offline  
Add Post to del.icio.us
Reply With Quote
Go Back   Webmaster Forum > Web Development > Web Design Lobby

Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
Web-Standards Validation bedlam17 Coding Forum 4 05-28-2007 12:03 AM
Javascript or PHP validation? ATLien Coding Forum 23 04-20-2007 02:53 PM
My first w3c validation awall19s brother SEO Forum 1 08-11-2006 09:56 AM
Image Validation Sketch Coding Forum 4 02-14-2006 06:05 AM
Validation Help / Javascript rodneyj Coding Forum 0 06-23-2004 10:16 AM


Sponsor Links
Get exposure! Get exposure! Find Scripts Web Hosting Directory Get exposure! SEO Blog


All times are GMT -7. The time now is 08:49 PM.
© Copyright 2008 V7 Inc