How to get file size from URL in Laravel 5?

By Hardik Savani | July 18, 2016 | | 1036 Viewer | Category : Laravel


Share this post:

We sometimes require to get file size from path in laravel, so if you need to get file size from url then no worry and you can get using File facade. File facade provide several function that way we can get size of file or image.

In bellow example i just give you path of my images folder inside public folder and one image, that give path as argument of size function:

Example:

{{ File::size(public_path('images/1461177230.jpg')) }}



We are Recommending you: