skip to Main Content

How to get the type of the user in laravel? – Phpmyadmin

I want the code to check if the current user category is admin or superadmin, it will show the edit panel @if (Auth::user()->category=='admin'||Auth::user()->category=='superadmin') <td class="center"> <a href="{{ route('Order.edit', ['id'=>$order->id ]) }}" class="btn btn-warning btn-sm custom"> <i class="glyphicon glyphicon-edit"></i> EDIT</a> </td>…

VIEW QUESTION

Laravel Get File Contents of Image but Not Working on Production Environment – CentOS

My code bellow working on localhost development <img class="img-fluid rounded-circle" src="{{ url('image?type=user&file='.Auth::user()->picture_file.'&mime='.Auth::user()->picture_mime) }}" alt="Image Description"> will access imageController with get method using this link image?type=user&file=USER000053.png&mime=image/png class ImageController extends BaseController { public function get(Request $request){ $file=Storage::disk($request->type)->get($request->file); return response($file,200)->header('content-Type',$request->mime); } } bellow…

VIEW QUESTION
Back To Top
Search