mysql查询在xamp中工作但不在服务器中工作

时间:2016-12-27 04:46:30

标签: mysql-error-1064

我在php中安装了主登录系统,它在XAMMP中运行完美但在服务器中它在注册页面中出错:

  

“出现错误!请再试一次!”

if(($db->query("INSERT INTO `".MLS_PREFIX."users` SET ?u", $user_data)) && ($id = $db->insertId()) && ($db->query("INSERT INTO `".MLS_PREFIX."privacy` SET `userid` = ?i", $id)) && ($db->query("INSERT INTO `".MLS_PREFIX."privacy1` SET `chart` = '1', `vip` = '1', `userid` = ?i", $id))) {
      $page->success = 1;
      $_SESSION['user'] = $id;
      $user = new User($db);
    } else
      $page->error = "There was an error ! Please try again !";

1 个答案:

答案 0 :(得分:0)

不要在背景中加入点;正确的语法是:

`dbname`.`tablename`