Skip to content

Instantly share code, notes, and snippets.

@AndriyShepitsen
Last active December 19, 2015 06:19
Show Gist options
  • Save AndriyShepitsen/5910515 to your computer and use it in GitHub Desktop.
Save AndriyShepitsen/5910515 to your computer and use it in GitHub Desktop.
Specifying_Route_Names_for_Controller_Actions
/* =home */
Route::get('/', array('as'=>'home', 'uses'=>'HomeController@index'));
/* =about */
Route::get('about', array('as'=>'about', 'uses'=>'AboutController@index'));
/* =news*/
Route::get('news/{id}', array('as'=>'news', 'uses'=>'NewsController@show'));
Route::get('real_estate_news', array('as'=>'real_estate_news', 'uses'=>'RealEstateNewsController@index'));
Route::get('news-for-buyers', array('as'=>'news_for_buyers', 'uses'=>'NewsForBuyersController@index'));
Route::get('news-for-sellers', array('as'=>'news_for_sellers', 'uses'=>'NewsForSellersController@index'));
/* =contact */
Route::get('contact', array('as'=>'contact', 'uses'=>'ContactController@index'));
Route::post('login', array('as'=>'login', 'uses'=>'LoginController@index'));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment