Posted by Olaf Schinkel on 10/03/07 10:48
Hello!
"artev" <mailnotspammm@notspamm.nn> schrieb im Newsbeitrag
news:rhjrxbm3q113$.1613timdc4883$.dlg@40tude.net...
> if by PHP_SELF
> I have some similar:
> /localhost/namefile.php
> is possible to extract only this :
> namefile.php
>
> (is possible also have only namefile -no extension-)
>
> or is there a specific function?
What you are lloking for ist: explode
Step by Step:
$array = explode("/", $PHP_SELF);
$x = count($array);
$phpfile = $array[$x-1];
Best
Olaf
Navigation:
[Reply to this message]
|