I'm quite new to Laravel and when I am going through a tutorial, I encountered this error. This is my code in 'testController.php'.
<?php
namespace app\Http\Controllers;
use app\Http\Controllers\Controller;
class testController extends \app\Http\Controllers\Controller {
public function getAbout()
{
return view('Learning.about') ;
}
public function getHome()
{
return view('Learning.index');
}
}
And this is my 'routes.php'.
<?php
Route::get('test', [
'as' => 'test',
'uses' => 'testController@getHome',
]);
Route::get('about', [
'as' => 'about',
'uses' => 'testController@getAbout',
]);
I would be really grateful if somebody could lead me to a solution and probably explain the cause as well to refrain from such error.
Thank You.
via Chebli Mohamed
Aucun commentaire:
Enregistrer un commentaire