Created
April 19, 2012 15:39
-
-
Save lukearmstrong/2421796 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
class Controller_Error extends Controller_Template | |
{ | |
public function action_404() | |
{ | |
// XXX: https://github.com/fuel/core/issues/515 | |
// I assume the line below only works when using PHP as an Apache Module as the 404 header is different for FastCGI. | |
//$this->response->status = 404; | |
// Fix for using PHP FPM (FastCGI) | |
$this->response->set_header('Status', '404 Not Found'); | |
$this->response->send_headers(); | |
// Serve 404 Page | |
$this->template->content = View::forge('errors/404'); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment