note 126065 added to functions.arguments
| From: | anisgazig at gmail dot com | Date: | Mon, 10 May 2021 06:48:14 +0000 |
| Subject: | note 126065 added to functions.arguments | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-216363@lists.php.net to get a copy of this message | ||
VALUE PASSED DIRECTLY NOT ARGUMENT SO UNDEFINE VARIABLE WILL BE SHOWN.
SO PASSING A VALUE DIRECTLY TO A FUNCTION PLEASE GLOBAL KEYWORD MUST BE USE BEFORE VARIABLE.
function myfunc22(){
global $arr;
return $arr;
}
$arr = [10,20];
echo "<pre>";
print_r(myfunc22());
echo "</pre>";
----
Server IP: 45.112.84.4
Probable Submitter: 45.112.85.242 (proxied: 103.120.33.26)
----
Manual Page -- https://php.net/manual/en/functions.arguments.php
Edit -- https://main.php.net/note/edit/126065
Del: integrated -- https://main.php.net/note/delete/126065/integrated
Del: useless -- https://main.php.net/note/delete/126065/useless
Del: bad code -- https://main.php.net/note/delete/126065/bad+code
Del: spam -- https://main.php.net/note/delete/126065/spam
Del: non-english -- https://main.php.net/note/delete/126065/non-english
Del: in docs -- https://main.php.net/note/delete/126065/in+docs
Del: other reasons-- https://main.php.net/note/delete/126065
Reject -- https://main.php.net/note/reject/126065
Search -- https://main.php.net/manage/user-notes.php