Re: Check if php file is an included file?

From: Date: Wed, 16 Jul 2003 06:28:13 +0000
Subject: Re: Check if php file is an included file?
References: 1 2  Groups: php.general 
Request: Send a blank email to php-general+get-155368@lists.php.net to get a copy of this message
You could simply check $_SERVER['PHP_SELF'], and if it's not 'file1.php', do your redirect. Good luck, Storm "John Manko" <xerid@adelphia.net> schrieb im Newsbeitrag news:3F13AC7D.1090707@adelphia.net... > If have file1.php that includes file2.php, is there any way > to check, from file2.php, if it is indeed included. In other words, > I don't want file2.php to display (rather redirect to file1.php) if it's > not being requested as a file1.php include file. > > did I confuse you? > > > >

« previous php.general (#155368) next »