note 31314 deleted from function.file-get-contents by didou
| From: | didou@php.net | Date: | Fri, 28 Nov 2003 16:37:55 +0000 |
| Subject: | note 31314 deleted from function.file-get-contents by didou | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-61083@lists.php.net to get a copy of this message | ||
Note Submitter: hhw@joymail.com
----
For somebody's machine running PHP < 4.3.0:
you can add this function.
It is binary-safe.
function file_get_contents($filename) {
$fd = fopen("$filename", "rb");
$content = fread($fd, filesize($filename));
fclose($fd);
return $content;
}