RE: [PHP-DEV] PHP 4.0 Bug #6078 Updated: Make get_included/requir ed_files() work even if files do not end i .php
| From: | Gustafson, Mårten | Date: | Mon, 18 Sep 2000 16:31:56 +0000 |
| Subject: | RE: [PHP-DEV] PHP 4.0 Bug #6078 Updated: Make get_included/requir ed_files() work even if files do not end i .php | ||
| Groups: | php.dev | ||
| Request: | Send a blank email to php-dev+get-33414@lists.php.net to get a copy of this message | ||
Great!
But, get_included_files() also returns require_once()'d files and vice
versa.
--Marten
> -----Original Message-----
> From: Bug Database [mailto:php-dev@lists.php.net]
> Sent: Monday, September 18, 2000 3:43 AM
> To: php-dev@lists.php.net
> Subject: [PHP-DEV] PHP 4.0 Bug #6078 Updated: Make
> get_included/required_files() work even if files do not end i .php
>
>
> ID: 6078
> Updated by: stas
> Reported By: marten@jerbro.se
> Status: Closed
> Bug Type: Scripting Engine problem
> Assigned To:
> Comments:
>
> Should be fixed in latest CVS.
>
> Previous Comments:
> --------------------------------------------------------------
> -------------
>
> [2000-08-10 17:02:35] stas@php.net
> Oh, sorry - seems that this insanity is indeed in the code. I
> just didn't look well enough (being sure this couldn't be
> there). I hope new include/require code will fix that, but in
> the meantime I reclassify this as a bug.
>
> --------------------------------------------------------------
> -------------
>
> [2000-08-10 16:54:48] marten@jerbro.se
> Sorry if my explanation was fuzzy.
>
> What i meant is this; in the snippet below
> get_included_files() returns an empty array because the
> required files do not end in .php.
>
> <?
> require_once('global.inc');
> require_once('sess.class');
> require_once('banner.class');
> require_once('cache.class');
> require_once('template.class');
>
> var_dump(get_required_files());
> ?>
>
> From the manual page for get_required_files();
> "As of PHP 4.0.1pl2 this function assumes that the
> required_once files end in the extension '.php', other
> extensions do not work."
>
> --------------------------------------------------------------
> -------------
>
> [2000-08-10 16:46:33] stas@php.net
> the four characters ".php" has no magical meaning, so every
> function that works with files works with whatever names they have.
>
> --------------------------------------------------------------
> -------------
>
> [2000-08-10 16:41:16] marten@jerbro.se
> Is it possible to make get_included_files() and
> get_required_files() to work even if the files
> included/required does not end with .php?
>
> --------------------------------------------------------------
> -------------
>
>
> Full Bug description available at: http://bugs.php.net/?id=6078
>
>
> --
> PHP Development Mailing List <http://www.php.net/>
> To unsubscribe, e-mail: php-dev-unsubscribe@lists.php.net
> For additional commands, e-mail: php-dev-help@lists.php.net
> To contact the list administrators, e-mail:
> php-list-admin@lists.php.net
>