You can use basename()
and $_SERVER['PHP_SELF']
to get current page file name
echo basename($_SERVER['PHP_SELF']); /* Returns The Current PHP File Name */
More Related Contents:
- want to convert a string into array [duplicate]
- Laravel combined OR AND Solution
- Select those record only from table 1 where city exist against state id in table 2 in PHP
- How to remove duplicate values from a multi-dimensional array in PHP
- create array tree from array list
- How do I iterate over the results in a MySQLi result set?
- What is the point of interfaces in PHP?
- How to fake $_SERVER[‘REMOTE_ADDR’] variable?
- Why is this PHP call to json_encode silently failing – inability to handle single quotes?
- Destroy PHP Session on closing
- new limit within php: 1000 fields per POST. Does someone know, if the number can be influenced?
- Setup HTTP expires headers using PHP and Apache
- Dynamic Paypal button encryption
- Best methods to clean up a hacked site with no clean version available?
- How can I access a deep object property named as a variable (dot notation) in php?
- Download CSV file using “AJAX”
- PHP remove all characters before specific string
- Bubble sort implementation in PHP? [duplicate]
- Laravel Recursive Relationships
- How can I properly URL encode a string in PHP?
- Generate an associative array from an array of rows using one column as keys and another column as values
- Codeigniter Transactions
- How to redirect to another page using PHP [duplicate]
- Can I trust PHP __destruct() method to be called?
- php – add two hours to date variable
- Moving array element to top in PHP
- How can I put my WAMP online for someone to access?
- PHP pass function name as param then call the function?
- Which MySQL datatype to use for an IP address? [duplicate]
- PHP, pass array through POST