Answer the question
In order to leave comments, you need to log in
How to fix error when accessing localhost/pages?
<?php
namespace App\Http\Controllers;
use Illuminate\Http\Request;
class PagesController extends Controller
{
public function getIndex() {
echo __METHOD__;
}
}
Route::controller('/pages','PagesController');
Whoops, looks like something went wrong.
1/1 BadMethodCallException in Macroable.php line 74: Method controller does not exist.
in Macroable.php line 74
at Router->__call('controller', array('/pages', 'PagesController')) in Facade.php line 237
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question