0

i installed a project on my www folder in wamp , but when i add new route and try to get it wil the browser i got page not found , i copied all laravel 4 files to local folder exclude publi folder and i put its content on www , and try my route , i got the same error :

the routes :

<?php

/*
|--------------------------------------------------------------------------
| Application Routes
|--------------------------------------------------------------------------
|
| Here is where you can register all of the routes for an application.
| It's a breeze. Simply tell Laravel the URIs it should respond to
| and give it the Closure to execute when that URI is requested.
|
*/

Route::get('/', function()
{
    return View::make('hello');
});

Route::get('about', function()
{
    return View::make('hello');
});

when i get to " localhost " , it works fine but when i get to " localhost/about" i got page not found and i modified paths and index files and same issue

2 Answers2

1

It's likely that rewrite_mod is disabled in your Apache installation.

Try enabling it. Here's how to do it

Community
  • 1
  • 1
Nahiyan
  • 510
  • 5
  • 19
  • when i use " a2enmod rewrite" in my cmd i got "'a2enmod' is not recognized as an internal or external command, operable program or batch file." ?? –  Apr 28 '15 at 16:29
  • Which web-server do you use: nginx, apache, built-in? – vanadium23 Apr 28 '15 at 16:36
  • I guess you're using Apache. Make sure you created an alias for a2enmod. You could have tried the 2nd answer in my link as well. I didn't want to repeat the answer as it has been already asked before. – Nahiyan Apr 29 '15 at 04:26
1

you can enable rewrite_mod :

Open the httpd.conf file and search for

"rewrite"

, then remove

"#"

at the starting of the line,so the line looks like.

LoadModule rewrite_module modules/mod_rewrite.so

then restart the wamp.

Hardy Mathew
  • 684
  • 1
  • 6
  • 22