CSS - Div Class Only Works 1x
Hi, I have apage where the div only works on the bottom on the page. I am trying to place it also in the center to divide content. Here is the CSS code:
Code: .doubleLine{ clear:both; position:relative; float:left; width:1172px; height:6px; background-image: url(images/common/double_line.gif); background-repeat: no-repeat; margin-left:37px; margin-right:0px; margin-top:6px; margin-bottom:6px; padding:6px 0px 6px 0px; } can anyone tell me why this div with an image won't appear between content? I havetried everything I could think of. thanks Similar TutorialsWhat's up folks, just looking for a bit of help on a dropdown issue. Here's the page in question. Here's the CSS: Code: #mainmenu li li { background:transparent none; float:none; height:22px; } #mainmenu li#windows li a { background:transparent none; color:#BA0000; padding:5px; text-align: left; font-size:11px; height:auto; } #mainmenu li#windows li a:hover { color:#FF7921; background-color:#6C6C6C; } li ul { display: none; position: absolute; margin-top:-1px; background:#eee; border:1px solid; border-color:#6C6C6C; border-top:0; z-index:600; width:127px; } li > ul { top: auto; left: auto; } li:hover ul, li.over ul { display: block; } This problem is a strange one: the dropdown list works as it is, however, if i ditch the #windows (which is from the parent list) and replace it with a class (adding the class into the parent list item as i should), the dropdown doesn't work the same. Any ideas why ? Thanks. hey, I got a table, every <td> in the table got the css class .regular. (<td class='regular'>). When the user moves their mouse over a row, that row should change color. This works with the following code: <tr onmouseover='this.className=\"hoverRow\"'> However, this only works if the td's in that row have no class set yet. And since all td's in my table have a class set allready, i cant use this. How can i overwrite the class of the td's by the class for the whole row? thanks in advance Using the following example: Code: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>Test</title> <style type="text/css"> a { display: block; } a.one.on, a:hover.one, a:hover.one.on { color: red; } a.two.on, a:hover.two, a:hover.two.on { color: orange; } a.three.on, a:hover.three, a:hover.three.on { color: green; } </style> </head> <body> <a href="#" class="one">one</a> <a href="#" class="two">two</a> <a href="#" class="three">three</a> <p> </p> <a href="#" class="one on">one</a> <a href="#" class="two on">two</a> <a href="#" class="three on">three</a> </body> </html> Notice how, in IE6 (works fine in FF), when the secondary style named 'on' is added, all 3 links in the 2nd set display the properties of the style: Code: a.three.on, a:hover.three, a:hover.three.on { color: green; } (since it is last in the list) rather than the style specified by their respective numbers (i.e. 'one', 'two' or 'three'). Is there a way to overcome this in IE. I've read several forums and know that the technique I'm trying to achieve is possible, however I can't seem to get it to work. Basically I'm trying to shift the background positions of both the list item I'm hovering over and the next list item. I'm sure its just a syntax error and not a logic error, anyways the code is below - any help would be greatly appreciated! Code: HTML Code <div class="menu"> <ul> <li><a href="#" class="search"></a></li> <li><a href="#" class="battery"></a></li> <li><a href="#" class="cart"></a></li> <li><a href="#" class="contact"></a></li> </ul> </div> CSS .search, .contact, .cart, .battery { width:100px; height:30px; margin-left:-1px; display:block; } .search { background-image:url(Images/search.png); } .contact { background-image:url(Images/contact.png); } .cart { background-image:url(Images/cart.png); } .battery { background-image:url(Images/battery.png); } ul li a.search:hover { background-position:0px 60px; } ul li a.search:hover ul li a[class=battery] { background-position:0px 60px; } Sorry for the lousy title, can't come up with better wording.... What I'm trying to say is can someone give me an example code of a css syntax that accept one css classname and add a few more properties to it under a different class name. Sort of like merging two classname into one. Thanks... well i sort of know why, because they render things differently but i have looked in my code and cant figure out why it will be different for ff click here I have pulled my last hair so I come to you with a red face. these tags are in the head section Code: h3 {color: blue} pink {color: blue} In the body I have Code: <h3> what color is it? </h3><BR> <pink> it should be blue </pink> both lines print in blue on FF. IE6 shows h3 in blue but pink is plain, black text. Please embarass me with a simple answer. Thanks in advance, stujo NEWB here. Working on a project that has a custom ul w/ background images and sub menus the css currently in place works for all browsers except IE when using the IE developer tool, I can see all the applied styles for the items. For some reason IE is just randomly throwing in a padding-top from somewhere that's screwing up the alignment. There is NO source css file referenced or noted as to where it's coming from. As soon as it's removed, it display properly. I have explicitly set the style in the UL and the li to have the correct padding, but IE just seems to ignore them and throws in a padding of it's own. ANY IDEAS here? Anyone? Beuller? I am trying to make a menu on my website and it works well on internet explorer 7. I went onto firefox to check it and it is not working so great. The link is:-alrwritingservices.co.uk. The css:- Code: .solidblockmenu{ margin: 0; padding: 0; float: left; font: bold 13px Arial; width: 100%; border: 1px solid #625e00; border-width: 1px 0; background: black url(backygnav.gif) center center repeat-x; list-style } .solidblockmenu li{ display: inline; } .solidblockmenu li a{ float: left; color: #FFFFFF; font-weight: bold; padding: 9px 11px; text-decoration: none; border-right: 1px solid white; } .solidblockmenu li a:visited{ color: white; } .solidblockmenu li a:hover, .solidblockmenu li .current{ color: white; background: transparent url(backgnavhover.gif) center center repeat-x; text-decoration: none; font-weight: bold; float: left; } The html:- Code: <ul class="solidblockmenu"> <li><a href="index.php" class="current">Home</a></li> <li><a href="about.php">About Me</a></li> <li><a href="samples.php">Samples</a></li> <li><a href="manual.php">Manual</a></li> <li><a href="testimonials.php">Testimonials</a></li> <li><a href="quote.php">Get A Quote</a></li> <li><a href="faq.php">FAQ Section</a></li> </ul> <br style="clear: left" /> How would i make it look better in firefox and would would be the hack for internet explorer. Is theer any help available on the internet about this? Many thanks in advance, Stevo Hi all, I got my css layout to work in Opera, which is already an achievement for a newbie like me. But I'm facing some problems with FF and IE. First: in both the header image is gone Second: in IE the menu images are shown too wide resulting in a messed up menu Third: IE for some reason widens up the sidebar and content so the sidebar is shown below and also the footer is misplaced. I'm still trying to debug it myself but I don't seem to be able to solve them. my blog Any help or ideas are appreciated. Kind regards, Jef Hi I have a website which works fine in Firefox, but has problems in Internet Explorer. can someone please have a look and see what is wrong? the positioning of the Div boxes go wrong in IE, and also it seems like the site is scretched vertically. many thanks I am new to style sheets, and I have been trying to get an entry level position with a web developer here close to me. They sent me a PSD and told me to layout using nothing but CSS and no tables. So I did so... and it looks fantastic in Firefox, but not at all good in IE. The only real problem is with the positioning.. the content color and size and everything seems to be fine.... all the positioning is done in the code on the website, where you can view source... I pasted the CSS code below, but doubtful it will help much. Can anyone offer me some help? The site is he http://www.eomnis.com/test the style sheet is here http://www.eomnis.com/test/css.css and i pasted the style sheet code below. Thanks for any help everyone. Aaron <style type="text/css"> body { background-image: url('images/main_background.jpg'); background-color:#000000; background-repeat: no-repeat; margin: 0px; } .top_text { font-size: 14px; font-family:Verdana, Arial, Helvetica, sans-serif; color:#FFFF00; font-weight:400; } .bold_grey{ font-size:11px; font-family:Verdana, Arial, Helvetica, sans-serif; color:#EEEEEE; font-weight:300; letter-spacing:inherit; } .small_text{ font-size:9px; font-family:Verdana, Arial, Helvetica, sans-serif; color:#EEEEEE; font-weight:300; letter-spacing:inherit; } form { font-family:Verdana, Arial, Helvetica, sans-serif; color:#FFFFFF; font-size:10px; font-weight:300; } .select { font-size:9px; height:15px; } .input { font-size:9px; height:16px; width:160px; } .zip { width: 94px; height:16px; font-size:9px; } .Footer_links{ color:#CCCCCC; font-size:14px; font-weight:300; text-decoration:none; } </style> I have the following CSS that I believe is valid, but it only works in IE. In fact in IE it works perfect, but in FireFox it does not display anything at all. Code: <div style="font-size:8px; text-align:left; background-color:red; width:100px;"><div style="font-size:8px; background-color:green; width:75px;"></div></div> What I am trying to do is display a rating. In the above example, the rating is 75/100, so a green bar 75px long over a red bar 100px long. Hi, I'm trying to create a transparent background for the main text part of a site. I have the following code in the .css file: Code: .dataContainer { background-image:url('/images/transluscentbg.png'); *background: none: filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src='/images/transluscentbg.png',sizingMethod='scale'); padding:10px; } and call it he Code: <html><head> <link rel="stylesheet" type="text/css" href="styles/kr.css" /> <meta name="description" content=""> <meta name="keywords" content=""> <script src="rollover.js" type="text/javascript"></script> </head> <body id={$styleName|lower}> <!-- BEGIN OUTER WRAP --> <div id="bodywrap"> <div id="logoSpace"> </div> <!-- BEGIN MAIN CONTAINER --> <div id="content"> <div id="contentBorders"> <div id="mainContent" class="clearfix map{$mapNum}"> <div id="navBar"> <div id="innerContent" class="clearfix"> {include file="nav.tpl"} <div class="goContent"> <div class="dataContainer"> lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum </div> </body></html> This works fine in Firefox, but .dataContainer has no transparent background in IE. HOWEVER! It does work in both IE and Firefox if, instead of using <div> tags, I put the content in a table (<table><tr><td class="dataContainer">). Anyone have any idea why this might be happening and how i might be able to get the <div> to work? Using Axure to create working prototypes for use in usability testing. The code created by Axure works well in IE7 but the function does not work in IE6...which I think, most of my usability testers will be using. What this code is trying to do is, click on a link in one box which automatically copies and pastes the code to destination box. The idea is to let the user copy and paste content from a previous message. Has anyone ever come across this issue? I'm sure it how IE handles .css but was hoping there may be a fix. Code: <DIV id=u23_rtf><span style=" font-family:'Arial'; color:#000000; font-size:15px;"><b>Message:</b></span></DIV></DIV> <SELECT id=u24 style="position:absolute; left:290px; top:558px; width:180px; height:22px; ; background-color:#FFFFFF; text-align: left ; font-family:'Arial'; font-size: 13px; color:#000000; font-style:normal; font-weight:normal; text-decoration:none" > <OPTION selected value="English">English</OPTION> <OPTION value="Spanish">Spanish</OPTION> </SELECT> <DIV id=u25 style="position:absolute; left:505px; top:623px; width:230px; height:18px; ; ; text-align: left ; font-family:Arial; text-align:left; word-wrap:break-word;" > <DIV id=u25_rtf><span style=" font-family:'Arial'; color:#000000; font-size:15px;"><b>Copy Previous Message</b></span></DIV></DIV> <SELECT id=u26 size=2 style="position:absolute; left:505px; top:646px; width:230px; height:120px; ; background-color:#FFFFFF; text-align: left ; font-family:'Arial'; font-size: 13px; color:#000000; font-style:normal; font-weight:normal; text-decoration:none" > <OPTION value="Contribute more to your / English">Contribute more to your / English</OPTION> <OPTION value="Happy Holidays / English">Happy Holidays / English</OPTION> <OPTION value="Hola / Spanish">Hola / Spanish</OPTION> <OPTION value="Time to consolidate / English">Time to consolidate / English</OPTION> </SELECT> Fixed. I got my css menu to work in Firefox and have it to show the way I want it to, but now in IE it just shows up as a list of course, the experienced people will no that by looking at the code which I hope you can help me out by fixing it, so here it is dont laugh. Code: ul#menu{ margin:0; padding:0; list-style-type:none; width:790px; display:block; height:40px; text-transform:uppercase; font-size:13px; background:transparent url("images/black.jpg") repeat-x top left; font-family:Helvetica,Arial,Verdana,sans-serif; } ul#menu li{ display:block; float:left; margin:0; pading:0; border-right:1px solid #ffffff; } ul#menu li a{ display:block; float:left; color:#ffffff; text-decoration:none; padding:12px 20px 0 20px; height:28px; } ul#menu li a:hover{ background:transparent url("images/blue.jpg") repeat-x top left; } Thank You I have the following CSS: Code: #leftcontent { position: absolute; top: 135px; left: 20px; width: 150px; border: 0px; } #centercontent { border: 1px solid #999999; top: 135px; margin-left: 170px; margin-right: 140px; } html>body #centercontent { margin-left: 170px; margin-right: 140px; } #rightcontent { position: absolute; top: 135px; right: 20px; width: 120px; border: 0px; } This works just fine in Firefox, but I see some problem in IE6. As I resize the width of IE window, the right border line of the center content disappears. Maybe this CSS has some problem; maybe html inside has some problem. I don't know exactly what is causing this, but I need to fix it. I don't want the right border line to disappear. I want it to be visible at all times. How can I fix this problem? How can I make the right border line visible at all times? (This is where I use this CSS.) is there anything special i need to do to get CSS to work with IE? Here is what i have above the </head> tag Code: <link rel="stylesheet" type="text/css" href="layout.css"> the layout.css has: Code: catheader { color:#ffffff; font-size: 14px; font-weight: bold; font-family: verdana; } then in the <body> i have Code: <catheader>My New Category</catheader> In netscape it shows correctly, in IE it doesnt read it at all. any ideas? Here's the css code. Code: .toolbar a:hover, .toolbar a:focus, .toolbar a:active { background-color:#F5F9FA; } .toolbar { border:0; padding:0; margin:auto; border-collapse:collapse; } .toolbar a { display:block; text-align:center; vertical-align:middle; white-space:nowrap; } .toolbar a:hover, .toolbar a:focus, .toolbar a:active { text-decoration:none; } It works fine when you hover over a link, it lights up the back of the td which is what I want. However I would like the whole td to act as a link. So wherever you move the mouse over the td it lights up and would link to the page, instead of just over the text. Any suggestions? |