For Laravel 5.x, use $storage_path = storage_path()
.
From the Laravel 5.0 docs:
storage_path
Get the fully qualified path to the
storage
directory.
Note also that, for Laravel 5.1 and above, per the Laravel 5.1 docs:
You may also use the
storage_path
function to generate a fully qualified path to a given file relative to the storage directory:$path = storage_path('app/file.txt');