|
| |
|
|
funk theory
Posts: 51 Joined: 11/6/2006 From: Kent, UK Status: offline
|
Horizontal and picture Help - 7/21/2009 18:46:02
Hi, I have spent about the last 4 days trying to get a page to work with just pure CSS and no tables, just using code only. This was quite a big step for me and Im close now and wondered if someone could help me please. My two main problems are; 1) i cant seem to keep the 7 links in my horizontal menu all centre, they tend to wrap and end up on two lines, heres my code: <div id="centeredmenu"> <ul> <li><a href="#">Tab one</a></li> <li><a href="#" class="active">Tab two</a></li> <li><a href="#">Tab three</a></li> <li><a href="#">Tab four</a></li> </ul> </div> and the css: #centeredmenu { float:left; width:100%; background:#fff; border-bottom:4px solid #000; overflow:hidden; position:relative; } #centeredmenu ul { clear:left; float:left; list-style:none; margin:0; padding:0; position:relative; left:50%; text-align:center; } #centeredmenu ul li { display:block; float:left; list-style:none; margin:0; padding:0; position:relative; right:50%; } #centeredmenu ul li a { display:block; margin:0 0 0 1px; padding:3px 10px; background:#ddd; color:#000; text-decoration:none; line-height:1.3em; } #centeredmenu ul li a:hover { background:#369; color:#fff; } #centeredmenu ul li a.active, #centeredmenu ul li a.active:hover { color:#fff; background:#000; font-weight:bold; } 2) I want to have my text on the left and my image on the right and I am totally baffled and have tried all the float commands but am very frystrated. My 'table' although I wont be using them will be centered with 800 pixels and the image will be on the right and the image is 300 px wide and 500 px high, help :(
|
|
New Messages |
No New Messages |
Hot Topic w/ New Messages |
Hot Topic w/o New Messages |
Locked w/ New Messages |
Locked w/o New Messages |
|
Post New Thread
Reply to Message
Post New Poll
Submit Vote
Delete My Own Post
Delete My Own Thread
Rate Posts
|
|
|