There are 5 magic constants(predefined) in php which will give the values depending on the page or place where they are used.
1. __LINE__ : The current line number of the file.
2. __FILE__ : The full path and filename of the file.
3. __FUNCTION__ : The function name.
4. __CLASS__ : The class name.
5. __METHOD__ : The class method name.
These are case-insensitive.
the O/P of the above was, 4 e:\s.php
Similarly you can use the other constants with classes and functions.