Skip to main content.
September 22nd, 2006

nifty php line

If you ever need to get the name of the page you are on, and you don’t need the path, this will do it for you:

ltrim((str_replace(dirname($_SERVER['PHP_SELF']),"",$_SERVER['PHP_SELF'])),"/\\");

Posted by wmyers in hints

This entry was posted on Friday, September 22nd, 2006 at 11:20 and is filed under hints. You can follow any responses to this entry through the comments RSS 2.0 feed. You can leave a response, or trackback from your own site.

Leave a Reply

You must be logged in to post a comment.