|
Posted by Chris Hope on 10/13/99 11:16
Chung Leong wrote:
> Yes. You can use debug_backtrace() to get the arguments to the calling
> function.
>
> function validate_arg()
> $trace = debug_backtrace();
> $args = $trace[1]['args'];
> }
But be aware that debug_backtrace() is only available from PHP 4.3.0 and
greater. If you are coding for an old version, or for a wide audience
that may be using an old version, then it may not be safe to use this
function.
--
Chris Hope | www.electrictoolbox.com | www.linuxcdmall.com
Navigation:
[Reply to this message]
|