Inc/Require within includes
| From: | Antonio | Date: | Wed, 23 Aug 2000 08:12:03 +0000 |
| Subject: | Inc/Require within includes | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-13097@lists.php.net to get a copy of this message | ||
Hi, I've been having some problems here - and I'm not sure whether
PHP allows this or not. Here's the issue:
Does PHP allow you to require one file from a script, and within the
required file, require a second file?
E.G.
<?php
require "required1.inc";
?>
---- and in required1.inc
<?php
require "required2.inc";
?>
----------
When I try to do this, I get a "Fatal error when opening required2.inc in
required1.inc".
Is there any way to get around this problem? Or am I doing something wrong?
Is having two nested required files a big no-no?
-Antonio