public function del_col() { try { $excel = new Excel(); $excel->set_maxcol($excel->get_maxcol() - 1); $result = array('status' => 'OK', 'msg' => $excel->get_maxcol()); echo json_encode($result); } catch (Exception $ex) { $result = array('status' => 'ERROR', 'msg' => $ex->getMessage()); echo json_encode($result); } }