Ad
PHP Laravel Routing Issue
My setup currently looks like this
application/controllers/register.php
class register_Controller extends Base_Controller
{
public $restful = true;
public function get_index()
{
return View::make('main.register');;
}
}
routes.php
Route::controller(Controller::detect());
Route::any('/', function()
{
return View::make('main.index');
});
Route::any('register',function()
{
return View::make('register.index');
});
mydomain.com works.
mydomain.com/index gives a laravel 404
mydomain.com/register gives a standard 404
What's strange is that shouldn't mydomain.com/register give me a laravel 404 error? This page indicates that WAMP was the cause, but my setup is on a Ubuntu VM running PHP5, Apache2, and mySQL.
Ad
Answer
With mod_rewrite on, try setting in apache configurations "AllowOverride All", it fixed it for me.
Ad
source: stackoverflow.com
Related Questions
- → "failed to open stream" error when executing "migrate:make"
- → October CMS Plugin Routes.php not registering
- → OctoberCMS Migrate Table
- → OctoberCMS Rain User plugin not working or redirecting
- → October CMS Custom Mail Layout
- → October CMS - How to correctly route
- → October CMS create a multi select Form field
- → October CMS - Conditionally Load a Different Page
- → How to disable assets combining on development in OctoberCMS
- → October CMS - Radio Button Ajax Click Twice in a Row Causes Content to disappear
- → OctoberCms component: How to display all ID(items) instead of sorting only one ID?
- → In OctoberCMS how do you find the hint path?
- → How to register middlewares in OctoberCMS plugin?
Ad