public function __construct() { parent::__construct(); $this->load->library(array('UserAuth', 'Http')); $this->load->model(['MLog']); $this->load->helper(array('api_filter_fields')); self::$_app_required_fields = C('app_filter_fields'); $this->post = json_decode(file_get_contents("php://input"), TRUE); // 从post中json字符串中解析出变量并合并到$_POST if (!empty($this->post)) { $this->post = xss_clean($this->post); $_POST = array_merge($_POST, $this->post); } else { $this->post = xss_clean($_POST); } $this->_select_service_by_url(); //过滤非法访问 //$this->_check_sign(); // 记录系统日志 $this->MLog->record($this->userauth->current(TRUE)); // 激活分析器以调试程序 //$this->output->enable_profiler(TRUE); }