@php $userid = Auth::user()->id; $baseUrl = asset('uploaded_images')."/"; @endphp @extends('layouts.app') @section('content')
@if($image)
Download : {{ $image->file_name}}
@if(!empty($image->password))
Password

Please enter your password,
this file is password protected.
@endif
@php $fileInfo = pathinfo($imagePath); $validExtensions = ['png', 'jpg', 'jpeg', 'webp', 'gif', 'svg', 'bmp', 'jfif']; @endphp @if(empty($image->password) && !empty($imagePath) && in_array($fileInfo['extension'], $validExtensions))
Image Preview
@endif
@else
No file found
File does not exist
@endif
@endsection @section('script') @endsection