I have a file classes.phpin which I declare a set of classes to be used in a series of pages. Then, on one page, I need to use another class declared in a separate file. Now this separate class uses some classes located in the file classes.php.
So on most pages I have:
[1]
<?php
require('classes.php');
[page code]
?>
which works great. The problem is with this particular page, which has:
[2]
<?php
require('classes.php');
require('separate_class.php');
[page code]
?>
and this does not work, because it separate_class.phpalso requires classes.php.
If I try this:
[3]
<?php
require('separate_class.php');
[page code]
?>
then this does not work, because now classes are not available for this page, even if they are declared inside the file separate_class.php.
classes.php, , , classes.php .
, , [2], , , , , ?