Hello, a very frustating Error stops me from start coding with laravel. I will explain it short and simple with an example:
The following code works just fine:
// app/routes.php
Route::get('/', array(
"as" => "home",
"uses" => "HomeController@Home"
));
It proceeds with the controller function named Home and everything looks pretty. But if i change the route parameter like this for example:
// app/routes.php
Route::get('/home', array(
"as" => "home",
"uses" => "HomeController@Home"
));
And open that adress I get the following error displayed at my browser:
Not Found
The requested URL /home was not found on this server. Apache/2.4.7 (Ubuntu) Server at 192.168.241.128 Port 80
I can't manage to get this fixed. Is there some config item i need to set or what causes this? :(
Is mod_rewrite enabled on your Apache server? If not, enable it and restart Apache.
Thank you! You helped me alot!
The mod was enabled but i still had to allow it for certain Directories in one of the configs!
For future reference: I've added the following entry to the apache.conf file:
<Directory /var/www/project_x/laravel/public>
Options Indexes FollowSymLinks
AllowOverride All
Require all granted
</Directory>
The Directory is the one i declared as my root directory in the default.conf (with "DocumentRoot /var/www/tcrafter/laravel/public")
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community