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 3 of 3
  1. #1
    Senior Coder
    Join Date
    May 2005
    Posts
    2,137
    Thanks
    96
    Thanked 72 Times in 72 Posts

    div id doesn't work

    I don't understand why none of my DIV's will work?

    http://www.rodgame.org/projects/xedia/index.html

    Index.html
    Code:
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
    <head>
    <meta http-equiv="content-type" content="text/html; charset=iso-8859-1" />
    <title>Xedia</title>
    <meta name="keywords" content="" />
    <meta name="description" content="" />
    <link rel="stylesheet" type="text/css" href="x.css" />
    </head>
    <body>
    <div id="header">..</div>
    
    <div id="leftnav">aaa
    <div id="content">bbbb
    
    </div></div>
    
    <div id="footer">ccc</div>
    
    </body></html>
    x.css
    Code:
    header {
      width: 100%;
      height: 100px;
      background-color: yellow;
    }
    
    leftnav {
      height: 500px
      width: 150px;
      background-color: black;
    }
    
    content {
      width: 100%
      height: 100%
      background-color: tan;
    }
    
    footer {
      height: 30px;
      width: 100%;
      background-color: blue;
    }
    Last edited by masterofollies; 02-22-2009 at 11:35 PM.

  • #2
    New Coder
    Join Date
    Feb 2009
    Location
    Jakarta, Indonesia
    Posts
    93
    Thanks
    2
    Thanked 20 Times in 20 Posts
    You forgot to assign the selector:
    #leftnav{

    http://www.w3schools.com/css/css_syntax.asp

  • Users who have thanked gun5 for this post:

    masterofollies (02-22-2009)

  • #3
    Senior Coder
    Join Date
    May 2005
    Posts
    2,137
    Thanks
    96
    Thanked 72 Times in 72 Posts
    Bingo, got it, thanks


  •  

    Posting Permissions

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