note 24284 rejected from function.fopen by jmcastagnetto

From: Date: Mon, 12 Aug 2002 10:01:43 +0000
Subject: note 24284 rejected from function.fopen by jmcastagnetto
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-34843@lists.php.net to get a copy of this message
I found PHP wrapper use "PHP" and version number (PHP/4.2.3-dev on my system) as the User-Agent to request remote files. However, some server will refuse to serve browsers other than Mozilla compatible, it will return a 403 code. So, how can I customize the User-Agent when I use fopen() or file() function to retrive a remote file? Many thanks. Don't tell me use fsockopen() instead.

« previous php.notes (#34843) next »