First time I have tried Route::view('/video/{id}', 'overlays/video', compact('id')]); with same error and thought it could be because of compact() function...
Nov 7, 2017
5
Level 1
Route::view dynamically not working
After doing something like this:
Route::view('/video/{id}', 'overlays/video', ['id' => $id]);
it throws: Undefined variable: id
It is intended to work only like this:
Route::view('/video', 'overlays/video', ['id' => 'my_id']);
or there is a way to send that variable like I tried but I'm doing something wrong?
Please or to participate in this conversation.