if IE 5.0 Not Working
http://madclassifieds.000k.net/lib/
<!--[if IE 5.0]>
<link href="ie5.css" type="text/css" rel="stylesheet">
<![endif]-->
It doesn't Work!!!!! why!!!!! URGHHHHH!
If I change it to
<!--[if IE]>
It will import into IE 5, but I can't just do that because it will mess up IE 6.
Roo posted this at 03:23 — 21st March 2005.
She has: 840 posts
Joined: Apr 1999
I don't know if this will do what you want or not but:
ALA - Article - A Backward Compatible Style Switcher
dk01 posted this at 06:08 — 21st March 2005.
He has: 516 posts
Joined: Mar 2002
Do you have php enabled on your server? If so you can try this:
<?php
include(\"sniffer.php\");
global $version, $browser;
if($browser==\"msie\" && $version==5) {
echo('<link href=\"ie5.css\" type=\"text/css\" rel=\"stylesheet\">'); // IE5 stylesheet
} else {
echo('<link href=\"others.css\" type=\"text/css\" rel=\"stylesheet\">'); // All others stylesheet
}
?>
Then make sure you have the php sniffer in the same directory and named "sniffer.php". This can be found here:
http://www.conxiondesigns.com/source/nolines.php?/cfg/apps/sniffer.php/
I will caution your. It is strongly recommended not to design a fork in your site. Its your call in the end but it is generally bad practice as it causes you to have to edit twice the code that you normally would.
-dk
Dragon of Ice posted this at 21:33 — 21st March 2005.
He has: 578 posts
Joined: Jun 2004
Unfortunatly, I don't have PHP.... it's annoying because I'm used to having it, even if just means a header and footer file that get included. I'm not doing everything different in IE 5, just a couple key elements. I don't really know how else I'd do it, considering IE 5 really messes it up without this code, and I can't send stuff just to IE 5 and not 6 other than this or a PHP code, which I can't use. I'll check out the ALA list.
[EDIT]
I checked out the ALA article, but it's in Javascript, and I think there's too many things to be messed up client side. Shouldn't the if IE 5.0 work?
andy206uk posted this at 13:57 — 22nd March 2005.
He has: 1,758 posts
Joined: Jul 2002
Like it has been said before. Don't fork your code. With a bit of effort you can make your code work in all browsers without codeforks.
Dragon of Ice posted this at 21:27 — 22nd March 2005.
He has: 578 posts
Joined: Jun 2004
Yeah! It works. I don't know why, but it works. It has part to do with the fact that I changed it to just 5, instead of 5.0, which affects all IE 5's instead. Infact, 5.0 isn't even owned. They shipped with 5.0000(?)2. Anway, I understand forking code is a bad idea, but I did this project a while ago, and right now I'm just trying to wrap it up, and yes I understand that I should be concentrating on good practice...but, it's too tough at this point in the project. I just have to get it done. Also, I'm having some display issues with my current site in IE 5. Does anyone have suggestions on how to fix the problem of the header without forked code? http://madclassifieds.000k.net/new (you have to see it in IE 5, it repeats, and has messed up alignment and a bunch of other stuff.
Dragon of Ice posted this at 23:05 — 23rd March 2005.
He has: 578 posts
Joined: Jun 2004
I understand that forking the stylesheets is not good, but I just didn't know what to do, so I used it on my new site. I have time before the launch, so if anyone would like to look at the code (http://madclassifieds.000k.net/new/) and help me get it unforked, I'd be very grateful. I just didn't see how I could not use them and send different info to IE 5 and IE 6, or adapt the code so it worked in all three.
Want to join the discussion? Create an account or log in if you already have one. Joining is fast, free and painless! We’ll even whisk you back here when you’ve finished.