I am following the tutorial at http://kohanaframework.org/3.3/guide/kohana/tutorials/error-pages for Kohana 3.3
The following code is at classes/http/exception/404.php
<?php
class HTTP_Exception_404 extends Kohana_HTTP_Exception_404 {
public function get_response(){
$view = View::factory('errors/404');
$view->message = $this->getMessage();
$response = Response::factory()
->status(404)
->body($view->render());
return $response;
}
}
When trying to give an incorrect url like
localhost/myapp/xyz
The following error comes up
ErrorException [ Parse Error ]:
APPPATH\classes\http\exception\404.php [ 3 ]
1 <?php
2 class HTTP_Exception_404 extends Kohana_HTTP_Exception_404 {
3
4
5
6
7
8
{PHP internal call} » Kohana_Core::shutdown_handler()
In bootstrap.php the code for init is
Kohana::init(array(
'base_url' => '/myapp/',
'errors' => TRUE,
'index_file' => FALSE,
));
How can I fix this? Thanks.