vendredi 25 août 2017

Laravel Page redirect is not working

Here's is My laravel(5.4) code that i am facing problem
I had created test laravel project with two pages home & about us
and mapped the file path using Apache v-host(www.test.com)
When i hit www.test.com it loads correctly to the index page but when i try to hit www.test.com/about It showing 404 error .But when i hit like this url http://ift.tt/2gbXE2S page loads properly I don't know its problem is in my code or Apache configuration or any other

controller:

public function index(){
    return view('pages.index');
}
public function about(){
    return view('pages.about');
}

Route :

// Home Page
Route::get('/','pagesController@index');
// About Us Page
Route::get('/about','pagesController@about');  

Apache conf:

   ServerAdmin webmaster@localhost
    ServerName test.com
    ServerAlias www.test.com
    DocumentRoot /var/www/html/test/public/




Aucun commentaire:

Enregistrer un commentaire