Wednesday, January 5, 2011

How to get current file name with php

<?php
$current_file_name = basename($_SERVER['REQUEST_URI'], ".php"); /* supposing filetype .php*/
echo $current_file_name;
?>

No comments:

Post a Comment