fai un po` di debugging del code.. stampa $agent e vedi se la variabile contiene qualcosa..

se poi comunque e` vuota,
sostituisci a:
codice:
$agent = getenv("HTTP_USER_AGENT");
function browser_in_use() {
global $agent;
$b =& $agent;
questo:
codice:
$agent = $_SERVER['HTTP_USER_AGENT'];
function browser_in_use() {
global $agent;
$b = $agent;
nel caso leggi qui..
http://it2.php.net/manual/it/function.get-browser.php