get_folder
get_folder($path); - this function is used to get the name of the last folder where the file is located (file folder)
the input Function accepts parameters:
$path – path to the file to get the last folder name (string). It can be either absolute or relative (relative to the script folder).
After testing, the function returns the result of its work to the script :
folder – the name of the last folder where the specified file is located (string) false – there is no such file (boolean)