php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login

Patch improved-isset-documentation for Documentation problem Bug #74842

Patch version 2018-12-30 03:11 UTC

Return to Bug #74842 | Download this patch
Patch Revisions:

Developer: girgias@php.net

Index: en/reference/var/functions/isset.xml
--- en/reference/var/functions/isset.xml
+++ en/reference/var/functions/isset.xml
@@ -3,7 +3,7 @@
 <refentry xml:id="function.isset" xmlns="http://docbook.org/ns/docbook">
  <refnamediv>
   <refname>isset</refname>
-  <refpurpose>Determine if a variable is set and is not &null;</refpurpose>
+  <refpurpose>Determine if a variable is declared and is different than &null;</refpurpose>
  </refnamediv>
  
  <refsect1 role="description">
@@ -14,18 +14,20 @@
    <methodparam choice="opt"><type>mixed</type><parameter>...</parameter></methodparam>
   </methodsynopsis>
   <para>
-   Determine if a variable is set and is not &null;.
+   Determine if a variable is considered set,
+   this means if a variable is declared and is different than &null;.
   </para>
   <para>
-   If a variable has been unset with <function>unset</function>, it will no
-   longer be set. <function>isset</function> will return &false; if testing a
-   variable that has been set to &null;. Also note that a null character
-   (<literal>"\0"</literal>) is not equivalent to the PHP &null; constant.
+   If a variable has been unset with the <function>unset</function> function, it will no longer be set.
+  </para>
+  <para>
+   <function>isset</function> will return &false; when checking a variable that has been assigned to &null;.
+   Also note that a null character (<literal>"\0"</literal>) is not equivalent to the PHP &null; constant.
   </para>
   <para>
    If multiple parameters are supplied then <function>isset</function> will
-   return &true; only if all of the parameters are set. Evaluation goes from
-   left to right and stops as soon as an unset variable is encountered.
+   return &true; only if all of the parameters are considered set.
+   Evaluation goes from left to right and stops as soon as an unset variable is encountered.
   </para>
  </refsect1>
 
@@ -56,8 +58,7 @@
  <refsect1 role="returnvalues">
   &reftitle.returnvalues;
   <para>
-   Returns &true; if <parameter>var</parameter> exists and has value other
-   than &null;. &false; otherwise.
+   Returns &true; if <parameter>var</parameter> exists and has any value other than &null;. &false; otherwise.
   </para>
  </refsect1>
 
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Tue Mar 19 10:01:30 2024 UTC