Re: [PHP] Re: getting a function name of the calling function

2002-05-03 Thread Joshua E Minnie
"Miguel Cruz" <[EMAIL PROTECTED]> wrote: [snip] > I'm guessing he wants to do something like a stack trace to figure out how > a function managed to get itself called with bad data. > > With utility functions that may get called hundreds of times in a single > run, that would be some really handy

Re: [PHP] Re: getting a function name of the calling function

2002-05-02 Thread CC Zona
In article <[EMAIL PROTECTED]>, [EMAIL PROTECTED] (Miguel Cruz) wrote: > I'm guessing he wants to do something like a stack trace to figure out how > a function managed to get itself called with bad data. > > With utility functions that may get called hundreds of times in a single > run, that

Re: [PHP] Re: getting a function name of the calling function

2002-05-02 Thread Miguel Cruz
On Wed, 1 May 2002, CC Zona wrote: > In article <[EMAIL PROTECTED]>, > [EMAIL PROTECTED] (Joshua E Minnie) wrote: > > > Does anybody know of any constants or predefined functions that will > > retrieve the calling functions name? For example: > > > > > function new_func($somedata) { > > ech

[PHP] Re: getting a function name of the calling function

2002-05-02 Thread Joshua E Minnie
"Cc Zona" <[EMAIL PROTECTED]> wrote: [snip] > A step up would be to use the error handling functions instead > . Then you can customize which errors get > reported to the user, under what circumstances, how, whether to forward the > reports to you as well, plus the oppor

[PHP] Re: getting a function name of the calling function

2002-05-02 Thread CC Zona
In article <[EMAIL PROTECTED]>, [EMAIL PROTECTED] (Joshua E Minnie) wrote: > What I am trying to do is create an error message within in a string that > whenever each function fails it echos this particular string out with it's > pertinent information. > > i.e. > $error_string = "Warning: unab

[PHP] Re: getting a function name of the calling function

2002-05-02 Thread Joshua E Minnie
What I am trying to do is create an error message within in a string that whenever each function fails it echos this particular string out with it's pertinent information. i.e. Does this sounds feasible or is there another way to generate a dynamic error message without giving the user to much

Re: [PHP] Re: getting a function name of the calling function

2002-05-01 Thread Philip Olson
> > Does anybody know of any constants or predefined functions that will > > retrieve the calling functions name? For example: > > > > > function new_func($somedata) { echo "I am function " . __FUNCTION__; > > echo "I am function ".get_func_name(); > > } > > ?> __FUNCTION__ will exis

[PHP] Re: getting a function name of the calling function

2002-05-01 Thread CC Zona
In article <[EMAIL PROTECTED]>, [EMAIL PROTECTED] (Joshua E Minnie) wrote: > Does anybody know of any constants or predefined functions that will > retrieve the calling functions name? For example: > > function new_func($somedata) { > echo "I am function ".get_func_name(); > } > ?> What wo