|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2016-11-17 05:58 UTC] requinix@php.net
-Status: Open
+Status: Suspended
[2016-11-17 05:58 UTC] requinix@php.net
[2016-11-17 05:58 UTC] requinix@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Wed Oct 29 06:00:01 2025 UTC |
Description: ------------ function myFunction($var1, $var2=3, $var3=4, $var4=5) { echo $var1."\n".$var2."\n".$var3."\n".$var4; } Test script: --------------- myFunction('Test Call', 3, 4, 10); Expected result: ---------------- I expect this Output: Test Call 3 4 10 Actual result: -------------- Actual Same: Test Call 3 4 10 But Issue is: Now see that I only want to change $var4 value in my function. All other default values will remain same. But I have to remember every value and pass it through the function. I am proposing a this change like this: myFunction('Default Value', $var4=10); so that Every developer can only pass value with specific variable name. This issue arises at many function when we used in our development. I think this change will be a big feature for developer.