knowing which file is including

From: Date: Sat, 27 Mar 2004 02:52:34 +0000
Subject: knowing which file is including
Groups: php.general 
Request: Send a blank email to php-general+get-181601@lists.php.net to get a copy of this message
Hi, A bit of a weird problem, am just curious if this can be done... I have a file called config.inc.php which has a require_once in it for lang_a.php and lang_b.php config.inc.php is being "included" by a.php and b.php presently config.inc.php is doing a require_once for both lang_a and lang_b, is there any way to determine which file is calling the config.inc.php (a or b) and then set the require accordingly? I dont think so but am just wondering as PHP has a crapload of solutions that I would probably never know of. Thanks, -Ryan

« previous php.general (#181601) next »