Try with
in lib.php
define("__LIB_PHP__",1);
in service.php:
define("__SERVICE_PHP__',1);
if (!__LIB_PHP__){
    require('lib.php');
}

__might__ this help

Regards,
Andrey Hristov

----- Original Message ----- 
From: "Roko Roic" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, November 28, 2001 12:18 PM
Subject: [PHP] nested include_once()


> If I use include_once() to include these files in main.php:
> 
> main.php
> ---------
> include_once('lib.php');
> include_once('service.php');
> ---------
> 
> And file service.php also has a line in it:
> 
> service.php
> ----------
> include_once('lib.php');
> ----------
> 
> Will lib.php get included twice or only _once() ?
> 
> I am wondering because get_included_files() acts kind of 'strange' and does
> not display files included from included files. Damn recursion :)
> 
> [OT] Is there a way to tail files that get read from a Linux filesystem.
> That could help me find out what gets included and when?
> 
> Cheers
> Roko
> 
> 
> 
> 
> 
> -- 
> 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