homepage Welcome to WebmasterWorld Guest from 23.20.220.61
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member

Home / Forums Index / Code, Content, and Presentation / HTML
Forum Library, Charter, Moderators: incrediBILL

HTML Forum

    
DIV resulting in parse error
can't get it to validate
tobeye




msg:4109869
 9:49 pm on Apr 4, 2010 (gmt 0)

Helo,
my css documents doesnt validate.I want to center my aligned menubar, but I cant select my UL. It returns a parse error, I tried allot of things but nothing helped, can you help me out? Do you see the answer to my question?






my html:

<div id="header">
<div id="logo">

<img src="./Image/0526_brick_003.jpg" width="800" height="200" alt="specifics removed" /> </div>
<div id="navigatie"> [b]<ul id="list">[/b]
<li id="nav1"><a href="../Home.html">Home</a></li>
|<li id="nav2"><a href="../contact.html">Contact</a></li>
|<li id="nav3"><a href="../projecten.html">Projecten</a></li>
|<li id="nav4"><a href="../partners.html">Partners</a></li>
</ul>
</div> <!--EINDE NAVIGATIE-->
</div> <!--EINDE HEADER-->



my css:
#list{
border:4px solid #000000;
margin:0;
list-style-type:none;
background-color:#5A585D;
width:50%;
display: block;
text-align:center;
}

#navigatie li {
margin-bottom:2px;
background-color:#5A585D;
display: inline-block;
text-align:center;
}
#navigatie a{
display:block;
color:#fff;
background-color:#AF0000;
padding:2px;
text-decoration:none;
}
#navigatie a.hier{
background-color:#5A585D;
color:#333;
}
#navigatie a:hover {
background-color:#999;
color:#fff;
}

[edited by: incrediBILL at 10:07 pm (utc) on Apr 4, 2010]
[edit reason] removed specifics, see TOS #13 [webmasterworld.com...] [/edit]

 

Fotiman




msg:4110121
 1:51 pm on Apr 5, 2010 (gmt 0)

You are including the | character outside of the <li></li> tags, which is not valid. <ul> can only contain <li></li> nodes, it can't contain text nodes.

tobeye




msg:4110387
 10:38 pm on Apr 5, 2010 (gmt 0)

i removed them,but the same error keeps on returning, my html-code validated but my css did not..

Fotiman




msg:4110418
 12:20 am on Apr 6, 2010 (gmt 0)

What is the validation error?

tobeye




msg:4114059
 12:38 am on Apr 12, 2010 (gmt 0)

parse error on #list

if I change #list to #ul it gaves same error

OPunWide




msg:4114280
 12:31 pm on Apr 12, 2010 (gmt 0)

I pasted your code in at the w3.org validator (http://jigsaw.w3.org/css-validator/validator) and it said that it was valid. What is telling you that it's invalid?

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / Code, Content, and Presentation / HTML
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved