Answer Posted / lakshmi
<?php
$path = "/home/httpd/html/index.php";
$file = basename($path);
$file = basename($path, ".php");
?>
Is This Answer Correct ? | 4 Yes | 0 No |
Post New Answer View All Answers
What is the best way to change the key without changing the value of a php array element?
What are the advantages of using php?
Explain me what is the importance of "method" attribute in a html form?
What are interfaces in php?
Explain what are the three classes of errors that can occur in php?
How do you remove whitespace from the beginning and end of a $string variable?
What is the function file_get_contents() useful for?
Name some of the constants in php and their purpose.
Why php is better?
Tell me how can we connect to a mysql database from a php script?
What is the use of extract function in php?
What are super global variables in php?
What is reference variable php?
What is the purpose of break and continue statement?
What is the difference between get and post in php?