note 8352 added to fread

From: Date: Thu, 07 Sep 2000 13:21:10 +0000
Subject: note 8352 added to fread
Groups: php.notes 
Request: Send a blank email to php-notes+get-4314@lists.php.net to get a copy of this message
If you are going to read a http:// file filesize won't work. Instad use -1 as parameter. // get contents of a file into a string $filename = "/usr/local/something.txt"; $fd = fopen ($filename, "r"); $contents = fread ($fd, -1); fclose ($fd); - Fredrik http://no.php.net/manual/function.fread.php

« previous php.notes (#4314) next »