Created
May 6, 2016 07:50
-
-
Save kurozumi/90c9ec3f60c66a35173bf677bdc39bfc to your computer and use it in GitHub Desktop.
【CodeIgniter3】コントローラー毎にエラーページを切り替える
This file contains 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 | |
defined('BASEPATH') OR exit('No direct script access allowed'); | |
class Hooks | |
{ | |
public function set_error_views_path() | |
{ | |
$CI =&get_instance(); | |
if(file_exists($dir_path = VIEWPATH . 'errors/' . strtolower(get_class($CI)) . '/')) | |
$CI->config->set_item('error_views_path', $dir_path); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment