Q. Which of the following functions is used to get the current script name in PHP?
β
Correct Answer: (D)
Both $_SERVER['PHP_SELF'] and $_SERVER['SCRIPT_NAME']
Explanation: Both $_SERVER['PHP_SELF'] and $_SERVER['SCRIPT_NAME'] provide the current script name.