Reverting this; the second parameter is indeed optional in versions

newer than 4.1.0 (also added a note to this effect).


git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@69875 c90b9560-bf6c-de11-be94-00142212c4b1
This commit is contained in:
Torben Wilson 2002-02-10 00:38:40 +00:00
parent 9c461fa1dc
commit 449fd13992

View file

@ -1,5 +1,5 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.119 $ -->
<!-- $Revision: 1.120 $ -->
<reference id="ref.filesystem">
<title>Filesystem functions</title>
<titleabbrev>Filesystem</titleabbrev>
@ -556,7 +556,7 @@ fclose ($fp);
<methodsynopsis>
<type>string</type><methodname>fgets</methodname>
<methodparam><type>int</type><parameter>fp</parameter></methodparam>
<methodparam><type>int</type><parameter>length</parameter></methodparam>
<methodparam choice="opt"><type>int</type><parameter>length</parameter></methodparam>
</methodsynopsis>
<para>
Returns a string of up to length - 1 bytes read from the file
@ -572,8 +572,8 @@ fclose ($fp);
Common Pitfalls:
</para>
<simpara>
People used to the 'C' semantics of fgets should note the
difference in how EOF is returned.
People used to the 'C' semantics of <function>fgets</function>
should note the difference in how <literal>EOF</literal> is returned.
</simpara>
<simpara>
The file pointer must be valid, and must point to a file
@ -581,6 +581,12 @@ fclose ($fp);
<function>popen</function>, or
<function>fsockopen</function>.
</simpara>
<note>
<para>
The <parameter>length</parameter> parameter is only optional in
PHP 4.1.0 and newer versions.
</para>
</note>
<para>
A simple example follows:
<example>