April 21st, 2004, 04:15 AM
-
CSS fot mac and pc platform
Hi all,
Just made a tables site runs oke on a pc but not on a mac.
So now i want to create a mac-css. How can i include the right css-file based on an user platform?????
Javascript or php??
April 21st, 2004, 07:27 AM
-
Javascript:
alert(navigator.platform) ;
April 21st, 2004, 07:40 AM
-
April 21st, 2004, 08:10 AM
-
the only downside is that some browsers can spoof others, eg Opera can pretend to be IE or Moz. You can only eschew this bu using Javascript object detection:
Code:
if (document.all && document.getELementById && !document.layers) isIE = true ;
if (!document.all && document.getELementById && !document.layers) isMoz = true ;
if (document.all && document.getELementById && document.layers) isOp = true ;
kapiche?