ID:               35306
 User updated by:  kpeters at monolithss dot com
 Reported By:      kpeters at monolithss dot com
 Status:           Bogus
 Bug Type:         Documentation problem
 Operating System: SuSE Linux 9.3
 PHP Version:      Irrelevant
 New Comment:

OK, I see that now.  It's still a bit obscure, though.  I 
suggest that a warning be added that on PHP < 5.1.0 only 
the three-parameter form is valid, and on PHP < 5.0.0 only 
the two-parameter form is valid.


Previous Comments:
------------------------------------------------------------------------

[2005-11-20 21:34:31] [EMAIL PROTECTED]

Read that page fully and you see it is correct.

------------------------------------------------------------------------

[2005-11-20 21:31:31] kpeters at monolithss dot com

Description:
------------
On both PHP 4.3.10 and PHP 5.0.3, when attempting to call
file_get_contents with five parameters as specified in the manual
(http://us3.php.net/manual/en/function.file-get-contents.php) I get the
following errors:

PHP 4.3.10:  
"Warning: file_get_contents() expects at most 2 parameters, 5 given"

PHP 5.0.3:
"PHP Warning:  file_get_contents() expects at most 3 parameters, 5
given"


Reproduce code:
---------------
$file = file_get_contents($filename, null, null, $offset, $maxlength);

Expected result:
----------------
I should get up to $maxlength bytes starting from $offset in $filename.

Actual result:
--------------
warning message as described above.


------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=35306&edit=1

Reply via email to