function parameters
| From: | (Marc Logemann) | Date: | Thu, 06 Jul 2000 09:00:22 +0000 |
| Subject: | function parameters | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-5190@lists.php.net to get a copy of this message | ||
Hi,
was there a change in function parameter passing between php4b4 and
latest 4.01pl2?
We coded some functions a little bit dirty in the following way:
function seeIt($one, $two, $three)
{}
seeIt(1,2);
seeIt(1,2,3);
in php4b4 there was no problem to call seeIt(1,2), in the function the
third parameter was no set then. In 4.01pl2 the call arguments seem to be
counted and compared against the function parms.
Its not a coding problem, because now i define the function with 2
parms and get the optional third via func_arg_nums() and func_get_arg().
Just a question to be sure where was the change exactly.
Loge
--
*------------------------*
* Marc Logemann *
* Programmer/Analyst *
*------------------------*