I've just started using "Laravel". But the code snippets isn't working.
inside my DemoController.php
<?php class DemoController extends BaseController
{
public $restful = true;
public $layout = 'layout.default';
public function get_index()
{
$this->layout->title = 'laravelpage';
$View = View::make('demo1.index' , array(
'name'=>'Laravel user',
'age'=>'28',
'location'=>'dhaka'));
$this->layout->content = $View;
}
}
and inside my index.blade.php
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>{{ $title }}</title>
</head>
<body>
{{ $content }}
</body>
</html>
my route is:
Route::controller('demo1','DemoController');
why it's showing this error?
How can I resolve it?