Re: Strange include
| From: | Chris Lee | Date: | Fri, 02 Nov 2001 00:54:55 +0000 |
| Subject: | Re: Strange include | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-73207@lists.php.net to get a copy of this message | ||
this '/' method looks kinda neet, but some vars get messed, ie $PHP_SELF,
just be carefull using it.
<?php
$INC = explode('/', $REQUEST_URI);
unset($INC[0]);
unset($INC[1]);
$INC = implode('/', $INC);
include_once($INC);
?>
Chris Lee
lee@mediawaveonline.com
"OòkóöårzòËèkó" <Lietuva@xxx.lt> wrote in message
news:11319093068.20011102012043@xxx.lt...
> Sveiki, php-general,
>
> I have a file index.php . I include file menu.php in index.php ( I
> write include('menu.php'); in index.php ) . I want to do like this:
>
> index.php/menu.php . That means, that index.php has to include menu.php
>
> index.php/second.php . That means, that index.php has to include
> second.php .
>
> I think that you already know what I'm talkking about. So how could
> I do it?
>
> Thank you....
>
>
>
> ____________________________
> 2001.11.02, penktadienis
> Marius Pertravèius
> iCQ: #125733984
> Lietuva@xxx.lt
>