Justtechjobs.com Find a programming school near you






Online Campus Both


php4-beta | 200004

[PHP4BETA] get_browser From: David W. Robinson (dwrobinson <email protected>)
Date: 04/30/00

Hi,

I had get_browser() working fine under php3. However, I am not
getting it to work under php4. For example, the following is an
example simple HTML file I wrote called test.php

<HTML>
<HEAD><TITLE>get_browser test page</TITLE></HEAD>
<BODY>
<?
        $browser = get_browser();
        print("You are using " . $browser->parent . "<BR>\n");
        print("<BR>$HTTP_USER_AGENT\n");
?>
</BODY></HTML>

The output of this file is

You are using 
Mozilla/4.0 (compatible; MSIE 5.0; Windows 98; DigExt)

You will notice that the $browser->parent does not seem to work.

In the php.ini file the entry is

[browscap]
browscap = /usr/local/lib/php/browscap.ini

This is just as it was in php3.ini. And browscap.ini does exist in
the directory listed.

Has anyone got any ideas? All help will be more than welcome

David

------------------------------
David W. Robinson, Ph.D.
Research Assistant Professor
Physiology and Pharmacology, L334
Oregon Health Sciences University
3181 SW Sam Jackson Park Road
Portland OR 97201

dwrobinson <email protected>
------------------------------

-- 
PHP 4.0 Beta Mailing List <http://www.php.net/version4/>
To unsubscribe, e-mail: php4beta-unsubscribe <email protected>
For additional commands, e-mail: php4beta-help <email protected>
To contact the list administrators, e-mail: php4beta-admin <email protected>