I have created a page. I hvae a sidebar which is a div. the problem is how do i get the other main content next to it? it shows up underneath. http://img29.imageshack.us/img29/9416/newpicture6jg.jpg I want the pictures next to the siderbar. here is the code for that <html><head> <style type= "text/css"> h1 {color: #C80000} h1 {text-align: center} i {color: teal} a {color: salmon} body {background-color: #380000} #linkstable align="left"{background-color: #330000; margin:0 auto;width:18%;} </style></head></body> <div id="linkstable"> <h3> <a href="cherryhome.htm">Home</a></h3> <h3> <a href"=contact-us.htm">Contact Us</a></h3> <h2><i> Inventory:</i></h2> <h3> <a href"=tables.htm">Tables</a></h3> <h3> <a href"=seating.htm">Seating</a></h3> </div> <a> <img border="0" src="monitor.gif" alt=""></a> <a> <img border="0" src="camcorder.jpg" alt=""></a> <a> <img border="0" src="keyboard.jpg" alt=""></a> </body> </html> Code (markup):
I think you want something closer to <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <style type="text/css"> h1 { color: #C80000; text-align: center; } i {color: teal} a {color: salmon} body { background-color: #380000; } div.main { width: 100%; } #linkstable { text-align:left; background-color: #330000; margin:0 auto; width:18%; float: left; } #content { width: 81%; float: right; } </style> </head> <body> <div class="main"> <div id="linkstable"> <h3> <a href="cherryhome.htm">Home</a></h3> <h3> <a href"=contact-us.htm">Contact Us</a></h3> <h2><i> Inventory:</i></h2> <h3> <a href"=tables.htm">Tables</a></h3> <h3> <a href"=seating.htm">Seating</a></h3> </div> <div id="content"> <a><img border="0" src="monitor.gif" alt=""></a> <a> <img border="0" src="camcorder.jpg" alt=""></a> <a> <img border="0" src="keyboard.jpg" alt=""></a> </div> </div> </body> </html> Code (markup): You need to name your i to a id or class though as well.
Shouldn't you not have a wrapper div for centering and keeping it accessible to those in 800x600s? And stylesheets ought to be external, too! And most people are currently switching to XHTML 1.0 STRICT now, as well.