From 8a4cfdb64982a397809688066b107c264091f230 Mon Sep 17 00:00:00 2001 From: Gwynne Raskind Date: Sun, 17 Jun 2007 11:55:54 +0000 Subject: [PATCH] - Better describe FILTER_VALIDATE_BOOLEAN's behavior (fixes bug #41305) - Minor grammatical tweaks - Tiny structural tweak git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@237908 c90b9560-bf6c-de11-be94-00142212c4b1 --- reference/filter/reference.xml | 26 +++++++++++++++++--------- 1 file changed, 17 insertions(+), 9 deletions(-) diff --git a/reference/filter/reference.xml b/reference/filter/reference.xml index d5521fada3..ad3293b7a1 100644 --- a/reference/filter/reference.xml +++ b/reference/filter/reference.xml @@ -1,5 +1,5 @@ - + @@ -11,16 +11,16 @@
&reftitle.intro; - This extension serves for validating and filtering data coming usually - from some insecure source such as user input. + This extension serves to validate and filter data coming from some insecure + source, such as user input. - The following filters currently exist, be sure to read the + The following filters currently exist; be sure to read the Filter Constants section for information that describes the behavior of each constant: Existing filters - + ID @@ -48,11 +48,19 @@ FILTER_VALIDATE_BOOLEAN "boolean" - - Returns &true; for "1", "true", "on" and "yes", - &false; for "0", "false", "off", "no", and "", - &null; otherwise. + FILTER_NULL_ON_FAILURE + + + + Returns &true; for "1", "true", "on" and "yes". + Returns &false; otherwise. + + + If FILTER_NULL_ON_FAILURE is set, &false; is + returned only for "0", "false", "off", "no", and "", and + &null; is returned for all non-boolean values. +