Yes, you can include foo.php which has another include in it and another and
another  ....  they will all appear to you as a one single file.

But, be careful though, do not reinclude them, or you'll create an infinite
loop.. use include_once instead


Sincerely,

 Maxim Maletsky
 Founder, Chief Developer

 PHPBeginner.com (Where PHP Begins)
 [EMAIL PROTECTED]
 www.phpbeginner.com




-----Original Message-----
From: Conover, Ryan [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, February 13, 2001 1:46 AM
To: [EMAIL PROTECTED]
Subject: [PHP] Include files


I have an include file foo.inc.  I want to call a function that is in
another include file,say anotherfoo.inc, from the foo.inc.

//Foo.inc

include "c:\\...\\anotherfoo.inc";

//other code

//end of include

can I call an include from another include?

I tried the above but it fails opening the other include.

Should I have the
'  "include"c:\\...\\anotherfoo.inc"  '
in the file that includes the Foo.inc?

ryan

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to