Morning all-
Btw, PHP question.
Anyone know (and remember I can't code php for fuck), how to make a script to detect whether it's ie and show imageie.gif and if not, show image.gif?
Thanks
(,
Sat 2 Oct 2004, 14:03,
archived)
Btw, PHP question.
Anyone know (and remember I can't code php for fuck), how to make a script to detect whether it's ie and show imageie.gif and if not, show image.gif?
Thanks
but remember that browsers lie about what they are all the time - and defining "IE" can get a bit tricky (does Maxthon count, for example?)
(,
Sat 2 Oct 2004, 14:10,
archived)
www.mozilla.org.uk/products/firefox/
it's just the site i'm making is going to be viewed by computer illiterate mothers, and they'll most likely all use ie, so I want it to work for both.
(,
Sat 2 Oct 2004, 14:22,
archived)
it's just the site i'm making is going to be viewed by computer illiterate mothers, and they'll most likely all use ie, so I want it to work for both.
i take it you didn't read any of those links? you *can* get IE to use the full alpha channel with a little bit of css hackery.
(,
Sat 2 Oct 2004, 14:25,
archived)
they will prove very handy I'm sure.
(,
Sat 2 Oct 2004, 14:28,
archived)
Sorry.. *ashamed look*
(,
Sat 2 Oct 2004, 14:39,
archived)
I know!
use if (stristr($HTTP_USER_AGENT, "MSIE")) { echo "<img src="\" />"; } else { echo "<img src="\" />"; }
(Probably managed to add an error somewhere, as I'm thick, but thats the jist of it. And I can't be bothered to fix the image codes. Oh well.)
(,
Sat 2 Oct 2004, 14:12,
archived)
use if (stristr($HTTP_USER_AGENT, "MSIE")) { echo "<img src="\" />"; } else { echo "<img src="\" />"; }
(Probably managed to add an error somewhere, as I'm thick, but thats the jist of it. And I can't be bothered to fix the image codes. Oh well.)
(so at least throw away anything that contains "Opera")
hate to say it, but server-side browser-sniffing is a horribly-flawed idea.
EDIT: also, when the overwhelming market-share is held by (in this case) the lowest common denominator (IE), you really want to be doing it the other way around - serve the gif by default, and the png only to certain select browsers.
(,
Sat 2 Oct 2004, 14:19,
archived)
hate to say it, but server-side browser-sniffing is a horribly-flawed idea.
EDIT: also, when the overwhelming market-share is held by (in this case) the lowest common denominator (IE), you really want to be doing it the other way around - serve the gif by default, and the png only to certain select browsers.