|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #13163 Problems with including from within included files
Submitted: 2001-09-05 23:51 UTC Modified: 2001-09-06 11:00 UTC
From: colin at maven dot com dot au Assigned:
Status: Not a bug Package: Class/Object related
PHP Version: 4.0.6 OS:
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
Solve the problem:
37 + 19 = ?
Subscribe to this entry?

 [2001-09-05 23:51 UTC] colin at maven dot com dot au
There definately seems to be some issues with including or requiring files from within other files that have been included in the same fashion.  Say I have a file called "test.php" in the docroot that includes "file1.php".

The included file contains some class definitions which inherit from classes defined in "file2.php", so at the top of "file1.php" I have:


This does not seem to work.  It is finding the file correctly, but I receive "Cannot inherit from undefined class" errors.  If I manually include "file2.php" within the "test.php" file along with the "file1.php", it works fine.

Is this meant to happen, or is it a bug or known issue?


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2001-09-06 11:00 UTC]
One report per bug please.

PHP Copyright © 2001-2023 The PHP Group
All rights reserved.
Last updated: Sun May 28 05:03:46 2023 UTC