Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2

Thread: Please Help

  1. #1
    New Coder
    Join Date
    Jun 2012
    Posts
    20
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Please Help

    Hi, I am fairly new to HTML and CSS. I have a problem using the <li> and <ul> tags. I used the W3 Validator and this came up:

    'document type does not allow element "li" here; missing one of "ul", "ol", "menu", "dir" start-tag'.

    What does this mean exactly? Here is the piece of code:

    '<div id= "left-side-nav">
    <ul>
    <li><b>Other Pages<br />on Apple</b></li>
    <br />

    <li><a href= "Apple.php">Main Page</a></li>
    <br />

    <li><a href= "iOS6.php">iOS 6</a></li>
    <br />

    <li><a href= "iOSVersions.php">iOS Versions</a></li>
    <br />

    <li><a href= "iPhone5Rumours.php">iPhone 5 Rumours</a></li>
    <br />

    <li><a href= "OnMyiPhone.php">What's on<br />my iPhone</a></li>
    </ul>
    </div>

    Many thanks.

  • #2
    Regular Coder dan-dan's Avatar
    Join Date
    Aug 2009
    Location
    England
    Posts
    483
    Thanks
    22
    Thanked 79 Times in 78 Posts
    Get rid of those <br />. They're not valid. Instead use CSS to style your unordered list:

    Code:
    li {
    	margin-bottom: 10px;
    }
    Last edited by dan-dan; 06-18-2012 at 10:51 PM.
    Logic will get you from A to B. Imagination will take you everywhere.
    Albert Einstein


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •