Example #1
0
 function check_name()
 {
     $qs = query_string_to_array();
     $name = $qs['tbxRegisterNickname'];
     $this->load->model('user_model');
     $msg = array('Result' => true);
     if ($name) {
         if ($this->user_model->check_name($name)) {
             $msg = array('Result' => false);
         }
     }
     echo json_encode($msg);
 }
Example #2
0
 /**
  * 验证邮箱是否已存在 ajax
  *
  *
  */
 function check_email()
 {
     $qs = query_string_to_array();
     $email = $qs['tbxRegisterEmail'];
     $this->load->model('user_model');
     $msg = array('Result' => true);
     if ($email) {
         if ($this->user_model->check_email($email)) {
             $msg = array('Result' => false);
         }
     }
     echo json_encode($msg);
 }
Example #3
0
 function attach_timeSheet($commentID, $entityID, $options)
 {
     // Begin buffering output to halt anything being sent to the web browser.
     ob_start();
     $t = new timeSheetPrint();
     $ops = query_string_to_array($options);
     $t->get_printable_timeSheet_file($entityID, $ops["timeSheetPrintMode"], $ops["printDesc"], $ops["format"]);
     // Capture the output into $str
     $str = (string) ob_get_clean();
     $suffix = ".html";
     $ops["format"] != "html" and $suffix = ".pdf";
     $rtn["name"] = "timeSheet_" . $entityID . $suffix;
     $rtn["blob"] = $str;
     $rtn["size"] = strlen($str);
     return $rtn;
 }