I spend hours on this problem and hope to find a way out. I configured laravel correctly, created myapp project
My route.php file contains
Route::get('/', function()
{
return View::make('hello');
});
Route::get('/users', function()
{
return 'Users!';
});
When i started
http://localhost/myapp/public/
I ran laravel start page correctly
When i started
http://localhost/myapp/public/users
I get
The requested URL /myapp/index.php was not found on this server.
I do not know why it is looking for index.php.
When i started
http://localhost/myapp/public/index.php/users
I get a page with the text "Users". I should get this page on startup
http://localhost/myapp/public/users
instead.
Below is my .htaccess
<IfModule mod_rewrite.c>
<IfModule mod_negotiation.c>
Options -MultiViews
</IfModule>
RewriteEngine On
Rewritebase /myapp/
RewriteRule ^(.*)/$ /$1 [L,R=301]
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^ index.php [L]
</IfModule>
Any ideas? I am running Apache on Linux.
source
share