CSS - Css Border Problem In Firefox ..
It looks fine in IE. But went wrong in Firefox.
Also there seems to be a space to the right of each img button. :cry: IE http ://imgboost.com/uploads/894333_screenshot2.jpg FF http ://imgboost.com/uploads/113426_screenshot1.jpg My Css Quote: * { margin: 0; padding: 0; } html{ height: 100%; margin: 0; padding: 0; } body { height: 100%; font-family:Arial, Helvetica, sans-serif; font-size:12px; margin: 0; padding: 0; } * html #container { height: 100%; } #container { position: relative; min-height: 100%; } #buttons { padding-right: 0em; padding-left: 0em; } #topLinks { list-style: none; margin-top: 0; margin-left: 0; margin-right: 0; padding-top: 0.9em; padding-right: 0; background-image: url(../images/footer_bg.gif); background-repeat: no-repeat; } #topLinks li { display: inline; border-left: 1px solid #FFFFFF; padding-right: 0em; padding-left: 0em; } #topLinks li.topLinks_first { border-left: 1px solid #FFFFFF; } #topLinks li.topLinks_last { border-right: 1px solid #FFFFFF; } #topLinks a { color: #FFFFFF; } #header { padding-top: 5px; padding-left: 5px; margin: 5px; } #footer { width: 100%; text-align:center; position: absolute; bottom: 0; margin:0; padding:0; } #footer_pink { background: url('../images/footer_pink.gif') repeat-x; height: 35px; } #bottomLinks { font-family:Arial, Helvetica, sans-serif; font-size:11px; font-weight:bold; list-style: none; margin-top: 0; margin-left: 0; padding-top: 0.9em; background-image: url(../images/footer_bg.gif); background-repeat: no-repeat; } #bottomLinks li { display: inline; border-left: 1px solid #FFFFFF; padding-right: 1em; padding-left: 1em; } #bottomLinks li.first { border-left: 0 none transparent; } #bottomLinks a { color: #FFFFFF; } #footer_yellow { background: url('../images/footer_yellow.gif') repeat-x; height: 55px; } .footer_yellow { font-family:Arial, Helvetica, sans-serif; font-size:11px; font-weight:bold; color:#333333; } #footer_content { padding-top:1.0em; } #footer_yellow img { border: none; } #menu { background: url('../images/pink_menu.gif') repeat-x; height: 37px; text-align:center; } #menu a img { border: none; } #menu ul { padding:0px; margin:0px auto; } #menu ul li{ display:inline; list-style-type:none; } Similar TutorialsHi. Have created some simple tabs using table cells. Active tab should have bottom-border color equal to page background-color. Non-active tabs should have bottom-border=black. Works fine in IE, but does not work very well in Firefox. If I remove the border-collapse:collapse on the table, then firefox also work... but I would like to be able to keep the 1px border between each table cell. So is there a way to make this work in both IE and Firefox... and hopefully most other browsers... See code below: Code: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd"> <html> <head> <style type="text/css"> a.menu_top:link {color: #000000; text-decoration: none;} a.menu_top:visited {color: #000000; text-decoration: none;} a.menu_top:hover {color: #000000; text-decoration: none;} a.menu_top:active {color: #000000; text-decoration: none;} td.menu_top_passive { background-color: #777; border-left: 1px #000000 solid; border-right: 1px #000000 solid; border-top: 1px #000000 solid; border-bottom: 1px #000000 solid; text-align: center; cursor:pointer; font-weight: bold; padding: 5px 20px 5px 20px; margin: 0; } td.menu_top_active { background-color: #bbb; border-left: 1px #000000 solid; border-right: 1px #000000 solid; border-top: 1px #000000 solid; border-bottom: 1px #bbb solid; text-align: center; cursor:pointer; font-weight: bold; padding: 5px 20px 5px 20px; margin: 0; } </style> <script language="JavaScript"> function change(id, url) { for (i=1; i<6; i++){ eval("document.getElementById("+i+").className='menu_top_passive'"); } eval("document.getElementById("+id+").className='menu_top_active'"); } </script> </head> <body style="margin:0; padding:0; background-color:#bbb;"> <br><br> <center> 1. Load the page.<br> 2. Click Item 4.<br> 3. Click Item 2.<br><br> Why is the bottom border of the menuelements (table cells) not getting correct in Firefox?<br> None-active menuelements should have a border-bottom = black, active should have same bottom-border as page.<br> Notice that I use border-collapse on the table in order to get the cell-border 1px thick between the menuitems.<br> If I remove border-collapse, then there is no strange behaviour in Firefox.<br> Any way to get this working in Firefox without breaking it in IE? </center> <br><br><br> <table border="0" cellpadding="0" cellspacing="0" align="center" style="border-collapse:collapse;"> <tr> <td id="1" nowrap class="menu_top_active" onClick="change('1');"><a href="javascript:;" class="menu_top">Item 1</a></td> <td id="2" nowrap class="menu_top_passive" onClick="change('2');"><a href="javascript:;" class="menu_top">Item 2</a></td> <td id="3" nowrap class="menu_top_passive" onClick="change('3');"><a href="javascript:;" class="menu_top">Item 3</a></td> <td id="4" nowrap class="menu_top_passive" onClick="change('4');"><a href="javascript:;" class="menu_top">Item 4</a></td> <td id="5" nowrap class="menu_top_passive" onClick="change('5');"><a href="javascript:;" class="menu_top">Item 5</a></td> </tr> </table> </body> </html> I've got a layer on my page that I'm showing and hiding through javascript. The layer is positioned absolutely and given a position of right: 0 and bottom: 10px in the CSS file. Now in one case I actually went into the page and did an inline style to change the position. So that one is given a different position, top: -5px and left: 10px. In IE it works fine. In Firefox the border sometimes won't expand to enclose the box. Here's what I've found: -Take out the position from the CSS file and position with inline style -- works. -Leave the position in the CSS file and don't position with inline style -- works. -Leave position in CSS file and change right to left and change to any value -- works. -Leave position in CSS file and change bottom to top and change to any value -- doesn't work. So the big culprit here seems to be defining a position with bottom and then switching to top causes Firefox 1.5 or 2 to fail. The same thing seems to happen in Opera 9. This seems like a bug, but why in multiple browsers? I've tried floating things within the box, setting the overflow to auto, nothing seems to make the border expand around the box. Any thoughts? Can any of you tell me why with the a:link/visited set with border:none (as in the example at the bottom of the e-mail), I get a box around an image inside a link: <a href="communication.php"><img src="resources/president.jpg"></a> Working on a MAC, I noticed that the border only appears in Firefox but not in Safari, Opera and OmniWeb. Can anyone tell me why this border appears around the image, why only in FF, and of course, how one can make it dissappear using the stylesheet? STYLESHEET: a {text-decoration: none;} a:link { color: #000000; border: none;} a:visited { color: #000000; border: none;} a:hover { color: #bbbb00; border: none;} a:active { color: #000000; border: none;} .image{border-width:0px; border: none;} Trying to use css to make a border around an element, and am using: .navbar { border: 1px solid red; } In IE, it puts a border around the navigational bar, but in FF, it only puts 1 line above it. Even if I try independently adding: border-left border-right border-bottom etc, it only shows above for border-top and border-bottom and nothing for left and right. I can place the code if needed, but I really just have a few words typed to try and get this to work. It's of strict doctype if that matters. Does FF have something special I need to add to get border to work? Thanks. I just can't seem to see why Firefox only shows part of the border on the < ul> element. IE 6 seems OK. Here's the link: imagesandwords.org.uk/andrewjamesrp/index.php Here's the HTML: < div id="navcontainer"> < ul id="navlist"> < li>< a href="#1" title="Examples of the Work">Images< /a>< /li> < li>< a href="pages/about.php" title="About the artist">Andrew< /font>< /a>< /li> i etc for the other links < /ul> < /div> Here's the CSS: #navcontainer { color: #8d1016; font-weight: bold; width: 205px; padding: 20px 0 0 115px; } #navcontainer ul{ list-style: none; width: 90px; padding: 0; color: inherit; border: 1px black solid; } #navlist li { width: 90px; } #navlist li a { display: block; width: 100%; padding: 2px 14px; background-color: #E8E8E8; border: 2px solid #E8E8E8; background-image:url(siteimages/nav_arrow.gif); background-position:left center; background-repeat:no-repeat; text-decoration: none; } #navlist li a:hover{ color: black; background-color: #C0C0C0; border-style: outset; padding: 2px 14px; background-image:url(siteimages/nav_arrow02.gif); background-position:left center; background-repeat:no-repeat; } html>body #navlist li a:active { border-style: inset; } Why do the margin-top values on these layers DO NOTHING in firefox, but act as expected in IE? Which way is actually correct? Also, if I add a float:left to the blue layer, firefox adds a margin-top to the blue and green layers only? This seems very wrong.. How can I get the expected margin-top on each layer? Code: <BODY style="background-color:yellow;"> <div id='blue' style="width:250px; height:250px; display:block; margin-left:1px; margin-top:10px; background-color:blue; position:relative;"> <div id='green' style='width:220px; height:200px; margin-top:10px; background-color:green; display:block; position:relative;'> <!--- prod selector box ---> <div id='gray' style='width:200px; height:150px; overflow:auto; margin-top:10px; margin-left:4px; display:block; background-color:gray; position:relative;'> asdf </div> </div> </div> </BODY> Hey all, I am working on completely redoing our website (FizzPow.com) I have a border-right: on my left column in a wordpress template I am modifying. It looks fine in Chrome, IE9, Safari5, but in FF7, it moves my right column all the way down. Here's the site: FizzPow.com/newsite I am an experienced programmer but fairly novice with HTML/CSS. Please be kind and I very much appreciate your help! hi everyone, i have been trying to align border left/right correctly in ff but it always crates gap on top and bottom (see screenshot) while on ie it works as supposed to (screenshot below) here is my code Code: #center_container{margin-left:118px;margin-top:24px;} #center_container_text{ width: 522px; border-left:1px solid #757d7b; border-right:1px solid #757d7b; } #banners{float:right;margin-top:20px;margin-bottom: 10px;width:100px;border: 1px solid black;} Code: <div id="center_container"> <div id="banners"> <p>a</p> <p> </p> <p> </p> <p> </p> <p>asd</p> <p>asd</p> <p>as</p> <p>d</p> </div> <div><img src="images/box_header.gif" name="Categories_header" alt="" /></div> <div id="center_container_text"> <p>a</p> <p> </p> <p>asd</p> <p>asd</p> <p>as</p> <p>d</p> <p>asd</p> </div> <div><img src="images/box_bottom.gif" name="Categories_bottom" alt="" /></div> </div> thx. As you can see, the image that says view all clients has a blue border on top and to the left also. There are no borders set for this image so I am not sure why its there. It does not show up on safari, just firefox. (I am not sure about IE since I am on a mac). Here is the code: .view_all_projects{ width:245px; height:63px; position:absolute; overflow:hidden; margin: 550px 0 0px 0; } And here is the html: <div class="view_all_projects"><a href="http://www.bestdropshipper.net/order.html"><img src="images/more_project.gif" alt="Best Dropshipper"/></a> </div> This image is also clickable. Any ideas why the strange blue border? I have the following code which works fine in IE but not in firefox. <table width="100%" border="1" cellpadding="0" cellspacing="0" bordercolor="#FFFFFF"> <tr><td></td></tr> </table> IE displays just white space as intended, but firefox displays a black border line. I need a white border of 1 pixel around the table. In IE-only.com Firefox is extending the bottom border of my blogTitle divs the lenth of the page. The other browsers are fine with the code. Tested on FC4, and IE was tested on XP Home. All are the latest versions (Fx:1.5, Konqi:3.x, Opera: 8.5, IE: 6.x). Why would Firefox do this? How can I correct this? Thank you. Hello all, My website appears fine on Firefox 3.6.7 but not on IE 8 (it is missing the borders on the article text area and the login box is up too high). I notice you can't include URLs in the post for new members so any help is greatly appreciated. Thanks! Firefox is putting a gray border on most of my images. The border is sometimes on the bottom or off to the right. If I add padding to the images sometimes the border will go away. The images are not links. I have basically covered every option in CSS to eliminate the problem with no prevail my CSS: Code: body img{ padding: 0; border:none; -moz-border-radius: 0; -khtml-border-radius: 0; -webkit-border-radius: 0; border-radius: 0; -webkit-box-shadow: 0 0 0 #000; -moz-box-shadow: 0 0 0 #000; text-decoration: none; outline:none; overflow: hidden; } Hopefully someone has encountered this before or has some information to help? I am at a total loss on this one. I'm trying to create a simple inline unordered list menu - no problems there - I've done that plenty of times. However, this time I would like my menu to have a border around it instead of being a plain box. As soon as I add the 'border-style:solid' modifier to the div, the text misaligns straight down, roughly 15px lines, out of the box. This happens on Firefox (and apparently on Opera as well, though I haven't checked that one myself). At this point I've stripped the page to bare bones, switched from transitional to strict, tried float vs not, tried margins vs 0 margins, and padding vs 0 padding, relative vs absolute, and attempted to manually shift the text through negative positions as well. No joy. Css: Code: /* Navigation */ #nav { width: 821px; height: 18px; border: 1px; border-style: solid; border-color:red; } #nav ul { } #nav li { display:inline; float:left; background-color:#9E0C0C; text-align:center; color:white; font-family: arial, san-serif; font-size: 14px; font-variant: small-caps; } and page: Code: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" /> <meta http-equiv="content-type" content="text/html; charset=utf-8" > <link href="style.css" rel="stylesheet" type="text/css" media="screen"> </head> <body> <div id="nav"> <ul> <li>Home</li> <li>XXX</li> <li>XXX</li> <li>CCC</li> <li>HHH</li> <li>JJJ</li> <li>kkk</li> <li>KKK</li> </ul> </div> </body> </html> (As I said, I've stripped it to absolutely nothing else.) Any suggestions would be welcome. (ETA: Also tried changing text size in case a too-large font size was making the text 'pop out' of the box. That is also not it.) Hi, I am trying to apply a bottom-border to a TR element. The border shows fine in Firefox, but will not display in IE6. Any ideas what is causing this? Page: http://explosiveracing.net/wow-guild/forum/ CSS: http://explosiveracing.net/wow-guild/css/forum.css(Under the .headers declaration) Hi, I've got weird issue: I have three div's that are positioned relative below each other. Together they compose a box, where the top has a background, the middle has a background and the bottom has a background. The middle part holds content and can expand vertically so the box is flexible in height. The background tiles vertically so the picture of the border stays intact when it increases in height. The weird thing is that when a border is not defined for the middle part: PHP Code: border: 0px solid #ffffff; that FF gives it a default white border of some 5 pix or so. In IE it works fine. When I do define a border, the div shows properly, but then I have a border that I don't want (see example white border). I can define the border to be transparent: PHP Code: border: 1px solid transparent; but that only works in FF and not in IE (where it shows up black). I can also define the border to be none: PHP Code: border: 1px none #ffffff; But that works fine in IE, but in FF I get the 5px white border again.... Here's my css: PHP Code: .contentbin { position: absolute; margin: 0px; height: 475px; width: 780px; top: 146px; left: 222px; padding: 0px 0px 0px 0px; border: 0px solid #ff0000; z-index: 1; } .contenttop { position: relative; margin-top: 0px; margin-left: 0px; margin-bottom: 0px; margin-right: 0px; padding: 0px; width: 780px; height: 17px; border: 0px solid #ff0000; background-image:url(../images/contentvensters/contentframe_gr1.jpg); background-repeat: no-repeat; } .contentmid { position: relative; margin-top: 0px; margin-left: 0px; margin-bottom: 0px; margin-right: 0px; padding: 0px 0px 0px 0px; width: 780px; border: 1px solid transparent; background-image:url(../images/contentvensters/contentframe_midback.jpg); background-repeat: repeat-y; } .contentbottom { position: relative; margin-top: 0px; margin-left: 0px; margin-bottom: 0px; margin-right: 0px; padding: 0px; width: 800px; height: 17px; background-image:url(../images/contentvensters/contentframe_gr1_onder.jpg); background-repeat: no-repeat; } .contentpadder { position: relative; margin-top: 10px; margin-left: 20px; margin-bottom: 10px; margin-right: 10px; padding: 0px 0px 0px 0px; border: 0px solid #000000; } Here's the html: PHP Code: <div class="contentbin"> <div class="contenttop"> <img src="images/spacer.gif"> </div> <div class="contentmid"> <div class="contentpadder"> Example text </div> </div> <div class="contentbottom"> </div> </div> I've attached screenshots for the different situations. Any help is greatly appreciated! Cheers, Gurt Hi, here's the CSS layout: http://www.abhiram.astahost.com/newlayout4/ The menu layout has been taken from 'Suckerfish menus' in http://www.alistapart.com The curved borders has been taken from http://www.webreference.com/program..._borders/2.html I've been trying to make curved borders for the header and the content. It displays it just the way I want it to in Firefox, but for some reason, the content part is giving a big gap in IE. I've used the same code with minor adjustments for both header and the content, but there is a problem only with the content. I've spent 2 hours and am at my wits end. Any leads? Source: http://www.abhiram.astahost.com/newlayout4/index.html http://www.abhiram.astahost.com/newlayout4/mystyle.css http://www.abhiram.astahost.com/newlayout4/iefix.js Thanks. New to using CSS for layouts and I'm having an issue with getting an img to appear within a div without a border. Here's my code, with a screenshot showing below it: Code: <div class="leftmenu"> <div class="lnavbtn"> <img src="images/leftnavbtn1.gif" border="0"> </div> </div> .leftmenu { margin:0px; border:0px; padding:0px; width:150px; height:100%; background-color:black; } .lnavbtn { align:right; margin:0px; border:0px; padding:0px; } Even with all the padding/margin/padding 0 stuff, I still get a 2 px border around the image. I want it to be clean all the way around. This happens in firefox and IE. Any suggestions? Sorry problem solved! |