示例#1
0
 public static function createUser($data)
 {
     $sql = "INSERT INTO " . self::$table . " SET " . "email_user = '******'email_user']) . "'," . "login_user = '******'login_user']) . "'," . "password_user = '******'login_user'])) . "'";
     print $sql;
     parent::query($sql);
     return parent::queryError();
 }
示例#2
0
 static function deleteLogData($id_platform)
 {
     $sql = "DELETE FROM check_log WHERE id_platform = '" . $id_platform . "'";
     parent::query($sql);
     if (parent::queryError()) {
         self::$errors[] = parent::queryError();
     }
     return null;
 }
示例#3
0
 public static function checkInBase($data, $exceptions = array())
 {
     $condition = array();
     if (is_array($data)) {
         foreach ($data as $k => $v) {
             if (!in_array($k, $exceptions)) {
                 $condition[] = $k . ' = "' . parent::escapeString($v) . '"';
             }
         }
     }
     if (count($condition)) {
         $sql = "SELECT * FROM check_log\n                    WHERE " . implode(" AND ", $condition);
         $q = parent::query($sql);
         $r = parent::fetchAssoc($q);
         print parent::queryError();
         return $r['id_check_log'] ? $r['id_check_log'] : false;
     }
     return false;
 }
示例#4
0
 public static function deleteLogData($id_application)
 {
     $sql = "DELETE FROM check_log WHERE id_application = '" . $id_application . "'";
     parent::query($sql);
     if (parent::queryError()) {
         self::$errors[] = parent::queryError();
     }
     return null;
 }