|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2018-05-05 18:06 UTC] requinix@php.net
-Status: Open
+Status: Wont fix
-Package: Feature/Change Request
+Package: *General Issues
[2018-05-05 18:06 UTC] requinix@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Fri Oct 24 02:00:01 2025 UTC |
Description: ------------ Is it possible to make func_get_args return a hashed array instead of a numeric one? Possibly by adding an argument to it. Reproduce code: --------------- function changeProfileDetails($userId, $password, $surname){ echo "<!--\n"; foreach(func_get_args() as $key=>$val){ echo "$key=>$val"; } echo "-->"; } changeProfileDetails(1, "test", "whoCares"); Expected result: ---------------- <!-- userId=>1 password=>'test' surname=>'whoCares' --> Actual result: -------------- <!-- 0=>1 1=>'test' 2=>'whoCares' -->