I'm trying to call dynamic popup views in which I need to pass the data through the controller, I want the controller to be dynamic which will access the particular function and make the view accordingly. Basically i'm looking for something like this:
Route::post('/popup/{id}', 'PopupController@{$id}');
So basically suppose when it is called like this: mydomain.com/popup/id1
, it should call PopupController@id1
.
Help me out with this.