How to I make a call to a function where I want to use some default args and some some I pass in:
function genericlist (array $arr, string $name, [string $attribs = null],
[string $key = 'value'], [string $text = 'text'],
[mixed $selected = NULL], [ $idtag = false], [ $translate = false])
I only want to pass in $arr, $name, $selected and use the default values for everything else, how do I do that? I know I could pass in the default values and go in order but I there must me another way. Thank you.
Well, either you do pass the default values indeed, either you reorder the arguments so as to put $selected before all other optional arguments.
Also, you can request for named parameters on PHP development forums.