get file extension laravel
snippet in php

get file extension laravel

user7646

$path ="/some/path/to/myfilename.html"; 
$ext = pathinfo($path, PATHINFO_EXTENSION);//ext is "html"

file original extensions laravel

user3598

$extension = $file->getClientOriginalExtension();