Entry
How do I get __FILE__ to give the full path in included files, not just the filename?
Apr 9th, 2002 08:07
Peter Hullah,
In answer to my own question, now that I've found the answer:
I was using PHP4.0.0 in which __FILE__ only returned the filename, no path, for included files. This caused numerous problems, notably
with php-nuke which no longer worked.
This problem has been fixed in later versions and PHP4.1.2, currently the most recent, returns the full filename for __FILE__ in included files.
Get it from http://www.php.net/downloads.php