From 3fcea8983490507b5afdcb55b191e189e4d61207 Mon Sep 17 00:00:00 2001 From: Philip Olson Date: Fri, 23 Jul 2004 00:18:22 +0000 Subject: [PATCH] Added changes to make manual "more PHP 5 friendly", like changing "In PHP 4" to "As of PHP 4" git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@164053 c90b9560-bf6c-de11-be94-00142212c4b1 --- language/control-structures.xml | 15 ++------------- language/functions.xml | 4 ++-- language/variables.xml | 6 +++--- reference/http/functions/header.xml | 4 ++-- reference/http/functions/setcookie.xml | 17 +++++++++-------- reference/math/functions/round.xml | 6 +++--- reference/misc/functions/eval.xml | 4 ++-- reference/misc/functions/uniqid.xml | 5 ++--- reference/mysql/functions/mysql-change-user.xml | 6 +++--- reference/var/functions/serialize.xml | 6 +++--- reference/var/functions/unserialize.xml | 6 +++--- reference/vpopmail/configure.xml | 6 +++--- 12 files changed, 37 insertions(+), 48 deletions(-) diff --git a/language/control-structures.xml b/language/control-structures.xml index b3d9bce0ec..6c9e99b941 100644 --- a/language/control-structures.xml +++ b/language/control-structures.xml @@ -1,5 +1,5 @@ - + Control Structures @@ -476,23 +476,12 @@ for (expr1; expr2; expr3): statement; ...; endfor; - - Other languages have a foreach statement to - traverse an array or hash. PHP 3 has no such construct; PHP 4 does - (see foreach). In PHP 3, you - can combine while - with the list and each - functions to achieve the same effect. See the documentation for - these functions for an example. - - <literal>foreach</literal> - PHP 4 (not PHP 3) includes a foreach construct, much + PHP 4 introduced a foreach construct, much like Perl and some other languages. This simply gives an easy way to iterate over arrays. foreach works only on arrays, and will issue an error when you try to use it on a variable with a different diff --git a/language/functions.xml b/language/functions.xml index 13aa03b8a5..f5d256420c 100644 --- a/language/functions.xml +++ b/language/functions.xml @@ -1,5 +1,5 @@ - + Functions @@ -41,7 +41,7 @@ function foo($arg_1, $arg_2, /* ..., */ $arg_n) In PHP 3, functions must be defined before they are referenced. No - such requirement exists in PHP 4. Except when + such requirement exists since PHP 4. Except when a function is conditionally defined such as shown in the two examples below. diff --git a/language/variables.xml b/language/variables.xml index 95329cc313..efe139d6bf 100644 --- a/language/variables.xml +++ b/language/variables.xml @@ -1,5 +1,5 @@ - + Variables @@ -55,7 +55,7 @@ $t linkend="language.expressions">Expressions. - PHP 4 offers another way to assign values to variables: + As of PHP 4, PHP offers another way to assign values to variables: assign by reference. This means that the new variable simply references (in other words, "becomes an alias for" or "points to") the original variable. @@ -942,7 +942,7 @@ if (isset($_POST['action']) && $_POST['action'] == 'submitted') { In PHP 3, the array form variable usage is limited to - single-dimensional arrays. In PHP 4, no such restriction applies. + single-dimensional arrays. As of PHP 4, no such restriction applies. diff --git a/reference/http/functions/header.xml b/reference/http/functions/header.xml index 93fe32299e..64d4dd065f 100644 --- a/reference/http/functions/header.xml +++ b/reference/http/functions/header.xml @@ -1,5 +1,5 @@ - + @@ -201,7 +201,7 @@ header('Location: http://www.example.com/'); - In PHP 4, you can use output buffering to get around this problem, + As of PHP 4, you can use output buffering to get around this problem, with the overhead of all of your output to the browser being buffered in the server until you send it. You can do this by calling ob_start and ob_end_flush diff --git a/reference/http/functions/setcookie.xml b/reference/http/functions/setcookie.xml index 96beece377..413b61719e 100644 --- a/reference/http/functions/setcookie.xml +++ b/reference/http/functions/setcookie.xml @@ -1,5 +1,5 @@ - + @@ -31,12 +31,13 @@ - In PHP 4, you can use output buffering to send output prior to the call - of this function, with the overhead of all of your output to the browser - being buffered in the server until you send it. You can do this by calling - ob_start and ob_end_flush - in your script, or setting the output_buffering - configuration directive on in your &php.ini; or server configuration files. + As of PHP 4, you can use output buffering to send output prior to the + call of this function, with the overhead of all of your output to the + browser being buffered in the server until you send it. You can do this + by calling ob_start and + ob_end_flush in your script, or setting the + output_buffering configuration directive on in your + &php.ini; or server configuration files. @@ -201,7 +202,7 @@ In PHP 3, multiple calls to setcookie in the same script will be performed in reverse order. If you are trying to delete one cookie before inserting another you should put the - insert before the delete. In PHP 4, multiple calls to + insert before the delete. As of PHP 4, multiple calls to setcookie are performed in the order called. diff --git a/reference/math/functions/round.xml b/reference/math/functions/round.xml index 6cbcffaca0..3c16d0f182 100644 --- a/reference/math/functions/round.xml +++ b/reference/math/functions/round.xml @@ -1,5 +1,5 @@ - + @@ -66,8 +66,8 @@ echo round(5.055, 2); // 5.06 - The precision parameter is only - available in PHP 4. + The precision parameter was introduced + in PHP 4. diff --git a/reference/misc/functions/eval.xml b/reference/misc/functions/eval.xml index 6959a111f7..a9552ac110 100644 --- a/reference/misc/functions/eval.xml +++ b/reference/misc/functions/eval.xml @@ -1,5 +1,5 @@ - + @@ -33,7 +33,7 @@ A return statement will terminate the evaluation of - the string immediately. In PHP 4, eval returns + the string immediately. As of PHP 4, eval returns &null; unless return is called in the evaluated code, in which case the value passed to return is returned. In PHP 3, eval does not return a value. diff --git a/reference/misc/functions/uniqid.xml b/reference/misc/functions/uniqid.xml index ae313f9939..9e9f0f4b07 100644 --- a/reference/misc/functions/uniqid.xml +++ b/reference/misc/functions/uniqid.xml @@ -1,5 +1,5 @@ - + @@ -34,8 +34,7 @@ - The lcg parameter is only available in - PHP 4 and PHP 3.0.13 and later. + The lcg parameter was introduced in PHP 3.0.13. diff --git a/reference/mysql/functions/mysql-change-user.xml b/reference/mysql/functions/mysql-change-user.xml index 519386e76c..e27ff2cf88 100644 --- a/reference/mysql/functions/mysql-change-user.xml +++ b/reference/mysql/functions/mysql-change-user.xml @@ -1,5 +1,5 @@ - + @@ -33,8 +33,8 @@ - This function was introduced in PHP 3.0.13 and requires MySQL - 3.23.3 or higher. It is not available in PHP 4. + This deprecated function is only available in PHP 3 and requires MySQL + 3.23.3 or higher. diff --git a/reference/var/functions/serialize.xml b/reference/var/functions/serialize.xml index 367c25d94b..f52b7ecca6 100644 --- a/reference/var/functions/serialize.xml +++ b/reference/var/functions/serialize.xml @@ -1,5 +1,5 @@ - + @@ -53,8 +53,8 @@ In PHP 3, object properties will be serialized, but methods are - lost. PHP 4 removes that limitation and restores both properties - and methods. Please see the Serializing Objects section of Classes and Objects for more information. diff --git a/reference/var/functions/unserialize.xml b/reference/var/functions/unserialize.xml index 0384346059..36cd2fea07 100644 --- a/reference/var/functions/unserialize.xml +++ b/reference/var/functions/unserialize.xml @@ -1,5 +1,5 @@ - + @@ -63,8 +63,8 @@ function mycallback($classname) In PHP 3, methods are not preserved when unserializing a - serialized object. PHP 4 removes that limitation and restores - both properties and methods. Please see the Serializing Objects section of Classes and Objects or more information. diff --git a/reference/vpopmail/configure.xml b/reference/vpopmail/configure.xml index f7e25b459d..5d9b22534e 100644 --- a/reference/vpopmail/configure.xml +++ b/reference/vpopmail/configure.xml @@ -1,10 +1,10 @@ - +
&reftitle.install; - In PHP 4, these functions are only available if PHP was - configured with . + As of PHP 4, these functions are only available if PHP + was configured with .