first commit

This commit is contained in:
pakerpale
2020-06-10 06:19:03 +09:00
commit cd6b5b7832
6081 changed files with 624389 additions and 0 deletions

View File

@@ -0,0 +1,24 @@
<? if ( ! defined('BASEPATH')) exit('No direct script access allowed');
class Cm_Exception extends Exception {
public function __construct($type, $code, $msg) {
if($type=='json') {
header("Content-Type: application/json");
$arr = array();
$arr = array('code' => $code, 'msg' => $msg);
echo json_encode($arr);
exit;
} else if($type=='html') {
header("Content-Type: text/html; charset=UTF-8");
echo $code.'|||||'.$msg;
exit;
}
}
}