How to get div border to show?

vieya

New Member
Okay So I've been making this layout with div and I tried to center the div and everything and that worked but now I can't get the left and right border to show up.

Code:
#tie {
        height: auto;
	margin:auto;
	position:relative;
	width:900px;
	border-left: 1px solid #000;
	border-right: 1px solid #000;
	background:white;
}

that's the code I used but for some reason there is no border on the sides where I specified.
 
Last edited by a moderator:

PixelPusher

Super Moderator
Staff member
vieya, is there any content in this div? The css seems to be correct to me...the only thing I could say without seeing a live link, is try setting the height to a number or percentage instead of "auto". Can you post a link to the page with this div?
 

vieya

New Member
no there is no content in this div it's used to center the other elements on the webpage.
I have a div with an image as the image layout then I have a div for links under that layout and then I have a sidebar with information and an iframe for content.
I tried centering like this with something that's more simple like tables and regular typing which is probably why it works in those cases.
 
Top