PHP get current page
March 10, 2008
<?php
$currentFile = $_SERVER["PHP_SELF"];
$parts = Explode(‘/’, $currentFile);
echo $parts[count($parts) - 1];
?>
same as with
<?php
basename($_SERVER[’PHP_SELF’]);
?>
Rockman-x official site.
<?php
$currentFile = $_SERVER["PHP_SELF"];
$parts = Explode(‘/’, $currentFile);
echo $parts[count($parts) - 1];
?>
same as with
<?php
basename($_SERVER[’PHP_SELF’]);
?>
Possibly related posts: (automatically generated)
| chogydan on Make your linux ubuntu look li… | |
| sagar on Install Windows XP on SATA wit… | |
| James P on Make your linux ubuntu look li… | |
| Helen on Facts & Fallacy about our… | |
| Nick on Get URL Parameters Using … |