Forum Moderators: not2easy

Message Too Old, No Replies

borders

no borders showing

         

craign924

10:41 am on Sep 27, 2010 (gmt 0)

10+ Year Member



border not showing, i do not know why.

here is the style code





#footer
{
border-top: thin solid #CCC;

}



here is the html code on a php page

<div id="footer"> 

we


</div>


thanks,
craig

rainborick

12:42 pm on Sep 27, 2010 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



It's going to be something simple. Be sure there are no syntax errors in either your CSS or your HTML. Change the thickness of the border to 2px or more to see if the browser is rendering the border, but when it's set to 'thin' it just can't be seen because of some other issue. Add the border with a 'style' attribute on the <div> tag to see if some other setting is overriding your setting on #footer. Good luck!

Major_Payne

2:49 pm on Sep 27, 2010 (gmt 0)



Try:


#footer {
width: XXpx;
height: YYpx;
margin: 0 auto;
border-top: 1px solid #ccc;
}


You MUST set a width and height for the div. Use of "thin" is ok, but I like to tell browsers what I want.

Ron

craign924

3:24 pm on Sep 27, 2010 (gmt 0)

10+ Year Member



ty guys,

i think for some reason the stylesheet was not communicating
with the server, i disconnected and reconnected and it seemed to fix the problem.

ty again,
craig

anuseo

11:48 am on Sep 29, 2010 (gmt 0)

10+ Year Member



Border size must be define in pixels like 2px, 4px etc. otherwise it will not work properly in all browsers....

enigma1

2:35 pm on Sep 29, 2010 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Border size must be define in pixels like 2px, 4px etc.

It doesn't have to be, medium, thin, 2px etc should all work in all the browsers. Which browser you have the problem with?

craign924

6:28 pm on Oct 4, 2010 (gmt 0)

10+ Year Member



it was ie8 but it is fixed now

Major_Payne

8:16 pm on Oct 4, 2010 (gmt 0)



Would you post your solution for the benefit of others?

craign924

10:02 pm on Oct 4, 2010 (gmt 0)

10+ Year Member



here is what i was after and it works in all major browsers(ie8,ff,o,chrome,)



CSS:

.footer
{
background: #fff;
height: 200px;
width: 1000px;
border-top: thin solid #CCC;
display: block;
margin: auto;
padding-left: 25px;
}


HTML:

<div class="footer">

</div>

craig

Major_Payne

1:12 am on Oct 5, 2010 (gmt 0)



OK. Thanks.