<?php
if(isset($_SERVER['HTTP_USER_AGENT'])){
$agent = $_SERVER['HTTP_USER_AGENT'];
}
if(preg_match('/^Mozilla\/.*?Gecko/i',$agent)){
// process here for firefox browser
}
else {
echo "<script> JS her </script> }
?>
<?php if(strpos($_SERVER['HTTP_USER_AGENT'],'Firefox')!==false) { ?>
<?php } ?>
if(navigator.userAgent.indexOf('Firefox') == -1) {
// Ikke firefox, putt skriptet ditt her.
}