WhiteDragon
04-14-2009, 12:03 PM
I have a div setup that looks fine in FF3 and IE7 but in IE6 it's way off. Is there a way to style the <div> for IE6 without it affecting it's positioning for the other browsers?
|
Click to See Complete Forum and Search --> : Styling a <div> specificlly for IE6? WhiteDragon 04-14-2009, 12:03 PM I have a div setup that looks fine in FF3 and IE7 but in IE6 it's way off. Is there a way to style the <div> for IE6 without it affecting it's positioning for the other browsers? 6StringGeek 04-14-2009, 01:48 PM You could use conditional comments to call an ie6-only stylesheet, and put the offending classes/id's in it: <!--[if IE 6]><link rel="Stylesheet" type="text/css" href="ie6.css" /><![endif]--> Captainkewl 04-14-2009, 08:10 PM I agree with the above suggestion. Also remember that if your using floats for your layout, if you put display:inline in the css, it will increase compatibility with IE6 without affecting anything else WhiteDragon 04-15-2009, 09:53 AM I wanted this <div> to be touching the corner of another <div> and in just IE6 it won't look as it does in IE7 and FF3, arrrgh. lystar 04-15-2009, 11:37 AM Conditional comments as mentioned above are the way to go. Avoid CSS hack methods if at all possible. If you're still having issues can you could provide an image of what you're trying to accomplish? Did you make sure to link the IE6 only spreadsheet AFTER the normal one. If you didn't than your normal stylesheet will just overwrite the IE6 version you commented in. WhiteDragon 04-15-2009, 11:47 AM I thought there would be a way to style so that it leaves the positioning as it is for IE7\FF3 but adjust it to where it should be for IE6. Here is a link http://www.thecreativesheep.ca/site/indexpage12.html You see a little blue box in the bottom right hand corner when viewed in IE6 you'll see it's not touching the corner by it's off !! lystar 04-15-2009, 12:05 PM Take a look at this: Conditonal Comments w/ Internet Explorer (http://www.elated.com/articles/internet-explorer-conditional-comments/) If you use a conditional comment to target only IE6, you can insert the IE6 only styling rules wherever you want. I don't have a copy of IE6, so I can't view your page with it / help you figure out what IE6 is doing wrong. I would recommend tweaking the page so it looks right in IE6 (make sure you're playing with a backup of your page and not the original) Then take whatever rules you needed to get the job done, dump them into a new css file and comment in a <link> element to load the IE6 css AFTER you link to your normal css file. WhiteDragon 04-15-2009, 12:13 PM Yeah that seems like the best solution. Maybe you can help me with something else, for me that web page link the background images load slow or don't load at all in FireFox 3 how is it for you ? Referring to the link in message #6 lystar 04-15-2009, 12:23 PM Right now, I'm using FF3. The page loaded quickly for me, though I should note I'm at work on my companies super fast connection. The file size on the header image is 222KB, which is probably the issue. Most people these days are on a fairly fast connection and it probably won't be an issue. Try playing with different compression levels and find a happy medium between quality and file size. I should tell you too that your left border isn't lining up with the header (its sticking to far left) in my browser. Screen Resolution 1280x1024. WhiteDragon 04-15-2009, 12:31 PM Yeah the page loads terrible slow for me but I'm doing this on dial - up but all the images are loading ? I understand that one of the left borders is not lined up, which I will fix I just have a concern with the loading. lystar 04-15-2009, 01:33 PM As far as I can tell all the images are loading. There is a gray box with "creativesheep_logo" written in it... should there be an image there, or is it just a placeholder? Dial-up is definitely your issue. I wouldn't worry too much about it, unless you know that a lot of your target audience is using a dial-up connection. If you use Fire Fox as your normal browser, check out the Firebug (https://addons.mozilla.org/en-US/firefox/addon/1843) plug-in. It will let you look at the source HTML and CSS of any webpage AND let you edit it (read only) in place so you can test out different code before saving it. I think you'll find it especially helpful on a dial-up connection because you won't have to keep uploading files or refreshing pages while you are tweaking your layouts. Of course it won't help you develop for IE6 or 7 but it is one of the best plug-ins for a web developer to have installed (in my opinion anyway). WhiteDragon 04-15-2009, 03:32 PM So it's mostly my dial up connection which is why I can't load the images. I'm going to try browser shots and see if that loads the images. I am currently using firebug it does help but how can I edit a css live for a style sheet only for IE6? lystar 04-15-2009, 03:38 PM Images not loading at all for you is weird. I can't really explain that one, unless there's some time-out issue occurring. Do you have a screenshot of what the page -should- look like? Maybe there are graphics not loading for me that I'm just not noticing without a reference. As for firebug, like I said, it can't really help you solve IE issues. That was kind of an off-topic aside to make sure you were aware of the plug-in. WhiteDragon 04-15-2009, 03:45 PM Do you mind if you show me a screen shot of what you're seeing you can send it to me privately if you don't mind. lystar 04-15-2009, 03:58 PM See the attached file... I had to compress it a lot to get it under the 100kb file restriction on the forum. Should get the idea across though. WhiteDragon 04-15-2009, 04:09 PM Yup everything loads as it should. So then it must be something on my end hmmm, I wonder how I can fix so I can see it how you are seeing it, most of my audience will be viewing my site as they do with many sites not on dial-up so I'm a very small percentage I just would like to be able to view it as you see it on dial-up and I can't figure out how to be able to do that. I hope you don't mind but if you have either or both IE6 and IE7 could you show me screen shots of one or other or both? lystar 04-15-2009, 04:26 PM I've got IE7 on this machine. Give me a few minutes and I'll get you a screenshot. WhiteDragon 04-15-2009, 04:33 PM Alright, thank you lystar 04-15-2009, 04:36 PM Interesting.... IE7 is choking on the site right now. Status bar is at ~50% and it says 1 item remaining. There is also an image error box in that gray block. The blue box you were talking about is there as well. Again, sorry for the high compression. WhiteDragon 04-15-2009, 04:43 PM Alright, it loads good you don't have IE6 right ? There is one problem since flash is not working how come you're not seeing that and the same thing happens here that little flash icon with the text? lystar 04-15-2009, 04:53 PM The odd thing is, I do have flash installed in Firefox. IE is chugging away trying to find your flash file. Do you have one uploaded? or is the <object> just a placeholder until you get your flash content uploaded? I'm guessing that there is something not right in your html for the <object> element. I can't really get into trying to debug it right now. I'm at work, so I can do little more than browse. Try cutting the flash object out of the source for now and see what happens. If the page suddenly works, then you know there is an issue in the <object> markup. WhiteDragon 04-15-2009, 05:12 PM Don't worry, I have the flash element turned off so there is nothing wrong with your browser or mine in that respect :) What I am concerned about is why with IE7 we are both not seeing the "get flash icon" with the text associated with it but in FireFox it shows up. lystar 04-15-2009, 05:20 PM Are you sure the conditional comments you have it wrapped in are correct? Honestly, conditional comments are something I have yet to master. It usually takes me 3 or 4 tries to get them right. It seems to me that IE7 is trying to find and load the flash file (thats why in my screenshot, its still showing that there is 1 object left to load). Its not understanding that you have the file disabled... which is what leads me to believe there is something funky happening with your conditionals. WhiteDragon 04-15-2009, 05:51 PM ;-) No I have turned off the flash object. Don't worry nothing is wrong with your browser or mine :) What I had mentioned is if you view the page in FF3 then in IE7 do you see in FF3 there is a "Get flash" icon with some text how come that is not showing up in IE7 ? lystar 04-15-2009, 05:59 PM Yeah I understand what you are saying. But what I'm saying is that icon is not showing up because IE doesn't understand that you have the flash disabled even though you do. It is still trying to load a non-existent flash movie. WhiteDragon 04-15-2009, 06:09 PM Oh I understand is there something I could add to my code so that IE understands and shows that error message that is seen in FireFox 3 ? Edit: How come I can see the error fine, locally in IE7 ? lystar 04-15-2009, 08:26 PM Sorry for the slow reply. If you can see the error in IE7 locally then the error is probably in whatever path you have set for the flash file. Have you linked the object tag to any local directory? WhiteDragon 04-15-2009, 10:48 PM No I haven't linked the object tag to local directory, that is what I don't understand. webdeveloper.com
Copyright Internet.com Inc., All Rights Reserved. |