Posted by leo on 04/27/06 04:52
"thehuby" <thehuby@gmail.com> wrote in message
news:1146091551.632293.167980@v46g2000cwv.googlegroups.com...
> How do you get the name of the currently execting script?
>
> By this I mean the name of the include file that is being executed:
>
> File: include.php
> <?php
> //Call some function to display include.php or whatever my filename is
> ?>
>
> File: holder.php
> <?php
> inlcude( "include.php" );
> ?>
>
> I tried everything in the $_SERVER variable but to no avail - Googling
> it doesn't help as it all points to either the include method or the
> $_SERVER variable. These all just give me 'holder.php' or similar.
>
what is the output of $_SERVER['PHP_SELF']?
what is your php version?
[Back to original message]
|