Sent: 27 September 2005 03:20 PM
To: php-general@lists.php.net
Subject: Re: [PHP] __FILE__ and __LINE__ of calling scripts?
Thomas wrote:
>Hi,
>
>I want to find out if it is possible to get the file name and the line
>number of a calling script (__FILE__, __LINE_) from a calling cla
Thomas wrote:
Hi,
I want to find out if it is possible to get the file name and the line
number of a calling script (__FILE__, __LINE_) from a calling class
automatically.
Let me explain:
I have a db class which gets called in other classes. Now, when an sql error
occurs I would like to find o
Thomas wrote:
Hi,
I want to find out if it is possible to get the file name and the line
number of a calling script (__FILE__, __LINE_) from a calling class
automatically.
Let me explain:
I have a db class which gets called in other classes. Now, when an sql error
occurs I would like to find
> I want to find out if it is possible to get the file name and the line
> number of a calling script (__FILE__, __LINE_) from a calling class
> automatically.
debug_backtrace contains that info.
http://www.php.net/debug_backtrace
--
Scott Noyes
[EMAIL PROTECTED]
--
PHP General Mailing List (ht
Andy --
...and then Ns_Andy said...
%
% what's its use and how to use(Example)?
They're constants that identify where you are. I use __FILE__ so that I
don't have to keep tweaking my code when working in the development
environment:
# this will let us figure out where we are and then always
> what's its use and how to use(Example)?
>
> Thanks
> --
> Regards,
echo "Maybe you should fine a " . __FILE__ . " and " . __LINE__. " from
the manual???";
---John Holmes...
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
6 matches
Mail list logo