When and how to use this

Hi, I am having difficulty to understand on how and when to use this function dirname(FILE) ?
can you please enlighten my mind.

Thank you in advance.

FILE is one of the predefined constants that PHP makes available inside your scripts. It gives you the full path (with file name) of the current script. Calling dirname(__FILE__) will return the path to the directory of the current script. There is another constant, DIR which gives you the same information.