note 70250 deleted from function.fopen by nlopess
| From: | nlopess@php.net | Date: | Sun, 08 Oct 2006 17:24:54 +0000 |
| Subject: | note 70250 deleted from function.fopen by nlopess | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-118224@lists.php.net to get a copy of this message | ||
Note Submitter: joao_r_jose_at_gmail_dot_com
----
Be sure to trim all white space from your input variable before using fopen().
If you do:
$url='http://www.php.net ';
$handle = fopen($url, "r");
fclose($handle);
You'll get a 404.
But if you do:
$url='http://www.php.net ';
$handle = fopen(trim($url), "r");
fclose($handle);
It works ok.