View Full Version : Div position


lukejtharries
04-20-2006, 12:21 AM
I have a div layer that I want positioned exactly in the center of my page. I know how to do it in frames, but frames suck, so i'm trying to do it in css. My css for it looks something like this:
#top { position:absolute;
top:0px;
left:???;
width:760px;
height:165px;
}
what do i put for left if I want it in the center?

HeLpM3
04-20-2006, 01:00 AM
try 400 ;)

lukejtharries
04-20-2006, 01:01 AM
the site is designed to be all resolutions- That would turn out funny in 800*600

J to the izzosh
04-20-2006, 03:56 AM
I don't have much time to explain it, but see if you can't figure this example (http://jfweb.fastmail.fm/center/center.htm) out. I've explained it in a few other threads asking the same question, so try actually looking around a little bit for the answer if you don't understand how it works. ;)