note 46975 deleted from function.fwrite by betz
| From: | betz@php.net | Date: | Wed, 15 Dec 2004 22:08:15 +0000 |
| Subject: | note 46975 deleted from function.fwrite by betz | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-81836@lists.php.net to get a copy of this message | ||
Note Submitter: ceilingfish at hotmail spot com
----
If the text that is being written is also zero length, then this function returns zero, just as if
it had failed to write. eg
$blank = '';
if(!fwrite($somefilehandle,$blank,strlen($blank))
{
die 'Some write error';
}
else
{
echo "'$hi' written to file";
}
Will always output :
'Some write error'