June 21, 200818 yr Hey, Firstly im just learning and its my first time posting here so sorry if i make some noob mistakes. But basically i am making a stupid site, full of pointless info to try and get used to working with css. I designed the page and checked it with internet explorer, then one time i opened with firefox and it looked messed up. So im trying to fix the problem. I cannot host the site anywhere. So i hope this is an acceptable way of showing what i mean. Here is the Site in i.e http://i31.tinypic.com/16c3swn.jpg Here is the site in mz http://i31.tinypic.com/2u5vuhx.jpg Here is the css (sorry if its not neat) http://sourcepost.sytes.net/sourcepost/sou...source_id=30349 Even if you could tell me what causes this to happen, i could find out whats wrong myself.
June 21, 200818 yr Welcome to the forum! The first thing that I noticed is that your css syntax is incorrect. Instead of width = "250px"; use width:250px; If you could post your html and your css here it would be easier to try and debug
June 21, 200818 yr Author ok thanks. Html <html> <head> <link rel="stylesheet" type="text/css" href="niftyCorners.css"> <link rel="stylesheet" type="text/css" href="niftyPrint.css" media="print"> <link rel="stylesheet" href="float2.css" type="text/css"> <script type="text/javascript" src="nifty.js"></script> <script type="text/javascript"> window.onload=function(){ if(!NiftyCheck()) return; Rounded("div#adbox1","all","#FFF","#D4DDFF","smooth"); Rounded("div#adbox2","all","#FFF","#D4DDFF","smooth"); Rounded("div#adbox3","all","#FFF","#D4DDFF","smooth"); } </script> </head> <body> <div id="header"></div> <div id="leftcol"> <br> <div id="lcTitle"> Headings</div> <div id="lcLinks"> <ul> <li > <a href="firstp.html"> First</a></li> <li > <a href="firstp.html"> Second</a></li> <li > <a href="firstp.html"> Third</a></li> <li > <a href="firstp.html"> Fourth</a></li> <li > <a href="firstp.html"> Fifth</a></li> <li > <a href="firstp.html"> Sixth</a></li> <li > <a href="firstp.html"> Seventh</a></li> <li > <a href="firstp.html"> Eighth</a></li> </ul> </div> </div> <div id="rightcol"> <div id="adbox1"><p>Welcome, This is my website. This section will hold information about various things</p> <p>I'll fill this with relevent stuff later, at the moment this is just to fomat text.</p> </div> <div id="adbox2"><p>Welcome, This is my website. This section will hold information about various things</p> <p>I'll fill this with relevent stuff later, at the moment this is just to fomat text.</p> </div> <div id="adbox3"><p>Welcome, This is my website. This section will hold information about various things</p> <p>I'll fill this with relevent stuff later, at the moment this is just to fomat text.</p> </div> </div> <div id="content"> <div id ="nDeals"><img src="nDeals.gif"/></div> <div id = "conBox1"> <div id="conBoxTitle">Nvidia GeForce 8600GTS</div> <div id="ImG"><img src ="image1.jpeg" alt="random pic" width ="100" height ="100"/></div> <div id="conBoxCost">Price: <a href="newPage.html">£115.98</a></div> </div> <div id = "conBox2"> <div id="conBoxTitle">Nvidia GeForce 8600GTS</div> <div id="ImG"><img src ="image1.jpeg" alt="random pic" width ="100" height ="100"/></div> <div id="conBoxCost">Price: <a href="newPage.html">£115.98</a></div> </div> <div id = "conBox3"> <div id="conBoxTitle">Nvidia GeForce 8600GTS</div> <div id="ImG"><img src ="image1.jpeg" alt="random pic" width ="100" height ="100"/></div> <div id="conBoxCost">Price: <a href="newPage.html">£115.98</a></div> </div> <br> <div id = "conBox4"> <div id="conBoxTitle">Nvidia GeForce 8600GTS</div> <div id="ImG"><img src ="image1.jpeg" alt="random pic" width ="100" height ="100"/></div> <div id="conBoxCost">Price: <a href="newPage.html">£115.98</a></div> </div> <div id = "conBox5"> <div id="conBoxTitle">Nvidia GeForce 8600GTS</div> <div id="ImG"><img src ="image1.jpeg" alt="random pic" width ="100" height ="100"/></div> <div id="conBoxCost">Price: <a href="newPage.html">£115.98</a></div> </div> <div id = "conBox6"> <div id="conBoxTitle">Nvidia GeForce 8600GTS</div> <div id="ImG"><img src ="image1.jpeg" alt="random pic" width ="100" height ="100"/></div> <div id="conBoxCost">Price: <a href="newPage.html">£115.98</a></div> </div> </div> <div id="content2"> <div id="nNews"><img src="nNews.gif"/></div> <div class ="con2OutterBox"> <div class=con2Header>Entertainment</div> <div class=con2InnerBox> <div id="Con2Img"><img src="entLogo.jpg"/img></div> <div id="nTextLink"> <a href="new.html">Big Brother News</a><br/> <a href="new.html">Television News</a><br/> <a href="new.html">Celebs in Rehab News</a><br/> </div> </div> </div> <div class ="con2OutterBox2"> <div class=con2Header2>Sport</div> <div class=con2InnerBox2> <div id="Con2Img2"><img src="sportpic.jpg"/img></div> <div id="nTextLink2"> <a href="new.html">Churchill Cup</a><br/> <a href="new.html">Euro 2008</a><br/> <a href="new.html">Ronaldo On the Move ?</a><br/> </div> </div> </div> <div class ="con2OutterBox3"> <div class=con2Header3>Computers</div> <div class=con2InnerBox3> <div id="Con2Img3"><img src="entLogo.jpg"/img></div> <div id="nTextLink3"> <a href="new.html">Big Brother News</a><br/> <a href="new.html">Television News</a><br/> <a href="new.html">Celebs in Rehab News</a><br/> </div> </div> </div> </div> <div id="footer"> <div id="footerLinks"> <a href="page1.html">Home</a> :: <a href="page2.html">Articles</a> :: <a href="page3.html">About</a> :: <a href="page4.html">More</a> </div> <div id="footerText"><br> Copywrite 2008 - Robe Technology</div> </div> </body> </html> The css body { margin: 0px; padding: 0px; text-align: center; background: #ffffff; } #header { background-image: url(logo.jpg); width: 100%; height: 100px; } #leftcol { background: #FFF;/*e2f5e1*/ float: left; width: 20%; height: 500px; border-top: 1px solid #97ae95; /*border-bottom: 2px solid #97ae95;*/ } #leftcol a, ul { list-style-image: url(i3.gif); text-align: left; text-decoration: none; line-height: 20px; font-size: 1em; font-family: 'franklin gothic medium'; color: #14400e; } #lcTitle{ color: #729f70; font-family: 'lucida sans'; font-weight: bold; } #rightcol { background: #fff; float: right; width: 20%; height: 500px; border-top: 1px solid #97ae95; border-bottom: 0px solid #97ae95; } #content { background: #fff; float: left; width: 60%; height: 250px; border: 1px solid #97ae95; border-top: 1px solid #97ae95; border-left: none; border-right: none; } #conBoxTitle{ font-family: 'franklin gothic medium'; font-weight: bold; font-size: 0.9em; margin 30 30px; color: #8a2733; } #conBoxCost{ font-family: 'franklin gothic medium'; font-weight: bold; font-size: 0.9em; color: #526988; } #conBox1{ background-image: url(bg.jpg); repeat: no-repeat; padding-top: 30px; padding-left:30px; height ="211px"; width = "250px"; float: left; } #conBox2{ background-image: url(bg.jpg); repeat: no-repeat; padding-top: 30px; padding-left:30px; height ="211px"; width = "300px"; float: left; } #conBox3{ background-image: url(bg.jpg); repeat: no-repeat; padding-top: 30px; padding-left:30px; height ="211px"; width = "250px"; float: left; } #conBox4{ background-image: url(bg.jpg); repeat: no-repeat; padding-top: 30px; padding-left:30px; height ="211px"; width = "270px"; float: left; } #conBox4 a { font-family: 'franklin gothic medium'; repeat: no-repeat; font-weight: bold; font-size: 0.9em; color: #526988; } #conBox5{ background-image: url(bg.jpg); repeat: no-repeat; padding-top: 30px; padding-left:30px; height ="211px"; width = "270px"; float: left; } #conBox5 a { font-family: 'franklin gothic medium'; font-weight: bold; font-size: 0.9em; color: #526988; } #conBox6{ background-image: url(bg.jpg); repeat: no-repeat; padding-top: 30px; padding-left:30px; height ="211px"; width = "300px"; float: left; } #conBox6 a { font-family: 'franklin gothic medium'; font-weight: bold; font-size: 0.9em; color: #526988; } #conBox1 a { font-family: 'franklin gothic medium'; font-weight: bold; font-size: 0.9em; color: #526988; } #conBox2 a { font-family: 'franklin gothic medium'; font-weight: bold; font-size: 0.9em; color: #526988; } #conBox3 a { font-family: 'franklin gothic medium'; font-weight: bold; font-size: 0.9em; color: #526988; } #ImG{ margin 30 30px; height = "100px"; width = "100px"; border: 1px solid #596575; } #adbox1{ margin: 10 10%; background:#D4DDFF; color: #ffffff; font-family:'franklin gothic medium'; } #adbox2{ margin: 10 10%; background:#D4DDFF; color: white; font-family:'franklin gothic medium'; } #adbox3{ margin: 10 10%; background:#D4DDFF; color: #ffffff; font-family:'franklin gothic medium'; } #content2{ background: #ffffff; /*#e7faf4;*/ float: left; width:60%; height: 250px; border: 1px solid #97ae95; border-top: none; border-bottom: none; } #nNews{ } .con2OutterBox{ height: 200px; width: 250px; padding-bottom: 10px; padding-left: 30px; padding-right: 15px; float: left; } #Con2Img,#Con2Img2,#Con2Img3{ padding-top: 2px; height = 60px; width = 56px; border: 1px solid #c9d3cd; float: left; } #nTextLink a, #nTextLink2 a, #nTextLink3 a{ padding-left: 5px; float: left; color: #819b8b; font-size: 0.7em } } .con2Header,.con2Header2,.con2Header3{ padding-left:10px; font-weight:bold; font-family: 'franklin gothic medium'; font-size: 0.8em; text-align:left; } .con2InnerBox a ,.con2InnerBox2 a,.con2InnerBox3 a { } .con2Header{ height: 20px; background-image: url(con2header2.gif); repeat: repeat-x; } .con2InnerBox{ height: 180px; width: 250px; } .con2OutterBox2{ height: 200px; width: 250px; padding-bottom: 10px; padding-left: 10px; padding-right: 15px; float: left; } .con2Header2{ height: 20px; background-image: url(con2header2.gif); repeat: repeat-x; } .con2InnerBox2{ height: 180px; width: 250px; } .con2OutterBox3{ height: 200px; width: 250px; padding-bottom: 10px; padding-left: 10px; padding-right: 15px; float: left; } .con2Header3{ height: 20px; background-image: url(con2header2.gif); repeat: repeat-x; } .con2InnerBox3{ height: 180px; width: 250px; } #footer{ background: #678c66; clear: both; width: 100%; height: 100px } #footerText{ color: #d4f0d3; font-family: 'lucida sans'; font-weight: bold; text-align: center; } #footerLinks a:link { color: #d4f0d3; font-family: 'franklin gothic medium'; font-size: 0.9em; } #footerLinks a:hover { color: #fbbb76; font-family: 'franklin gothic medium'; font-size: 0.9em; } #footerLinks a:visited { color: #ffffff; font-family: 'franklin gothic medium'; font-size: 0.9em; }
June 21, 200818 yr ok, you have a few small problems at the moment. 1. Put a doctype at the top of your html document. Something like this will do: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> NOTE: you will need to remove your <html> tag and replace it with the above code. 2.As I already mentioned, correct your css syntax. Also remove the inline styles i.e <img src ="image1.jpeg" alt="random pic" [b]width ="100" height ="100"[/b]/> 3.You have multiple divs with the same id i.e <div id="ImG"> You should only have 1 id per page; these should be classes instead. You will then need to change your css from #ImG{ margin 30 30px; height:100px; width:100px; border: 1px solid #596575; } to .ImG{ margin 30px 30px; height:100px; width:100px; border: 1px solid #596575; } And last but not least I would build your website for FireFox first and then iron out any glitches in IE towards the end. Hope that helps.
June 21, 200818 yr An id refers to a unique, individual element in the html document and can be styled as such. Because an id is unique, it should only be used on one element per page. A class however refers to a group of elements that share certain css defined characteristics. For example, say you wanted certain elements to have blue text. You would define a class in your css: .blue_element { color:blue; } and then for each element that you wanted blue text you would assign the class, example: <p> class="blue_element">Here is my blue text</p> <a class="blue_element" href="mypage.html" title="mypage">My Blue Link"</a>
June 21, 200818 yr Author oh i see. i got the code working fine on mozilla now. But its messed up on i.e i dont understand it. I have 3 colums left center and right. left was assigned 20% of space center had 60% of space right has the other 20% the only way to get it to layout properly in firefox is to give the center 80% even though left and right were still assigned 20% each total 120% this causes it to mess up in ie. I dont get it.
June 22, 200818 yr Hey there, Commonly IE and FF don't get along and view things differently. Can you post a screen shot of how it looks in FF now and IE now? What version of IE are you using. IE6 for example is total sh!t and is a real bear to get anything to look good in that. Don't get frustrated. We're here to help.
June 22, 200818 yr Author goldstien - good name by the way, Ari goldstien from entourage is the greatest character ever!!! I changed from a liquid design too a fixed pixel design because i liquid was annoying me, but i still have problems i posted the other thead. Thanks
Create an account or sign in to comment