In a controller you are not supposed to use $table and $primaryKey variables. These are supposed to be in the models.
And for routing I suggest using named routes. For e.g.
Redirect::route('example');
ooh, $table and $primaryKey shouldn't be there, my mistake.
For routing I put this in my routes.php
Route::controller('countries', 'CountriesController');
And in my views I use this
{{ HTML::linkAction('CountriesController@getDelete', trans('countries.delete'), array('country_id'=>$country->country_id)) }}
What is the difference between Redirect::to and Redirect::route?
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community