[thelist] user agent strings
John Pye
john.pye at purplehouse.com
Thu Mar 8 10:04:09 CST 2001
>
> as for serving up separate style sheets, i've decided this is much safer
> than trying to write a cross-browser style sheet
>
I had to tackle this same problem recently. My solution was
. spacer images or
DIV's with <style>.m{margin:10}</style> for all table spacing
. no <IMG style=""> ANYWHERE
. careful with placement of <FORM> tags to hide undesired spacing
. two style sheets
. one for netscape with fonts as 8pt verdana
. another for everybody else as 11px verdana
(yes I know that's ridiculously small)
. this code to decide which to serve up
<CFIF Find("Mozilla/4.0",cgi.HTTP_USER_AGENT)
AND Find("Nav",cgi.HTTP_USER_AGENT)>
<link rel="stylesheet" href="/netscape.css">
<CFELSE>
<link rel="stylesheet" href="/creativebase.css">
</CFIF>
I've still got plenty of /issues/, but that seemed to go a lot of the way.
Hope that helps
John Pye
http://www.creativebase.com/
+44 (0)20 7258 6900
More information about the thelist
mailing list