[請益] insert 問題
小弟實在找不出來問題出在哪兒~
$id=time();
$date=date('l jS \of F Y H:i:s');
$sql= "INSERT INTO 'list' ('id', '標題', '日期') VALUES ('$id','{$_POST['post_title']}','$date')";
if(file_put_contents('./news.inc/'.$id.'.inc.php',$_POST['post_content'])){
$err=mysql_query($sql);
echo $sql."<br />";
echo mysql_error();
}
INSERT INTO 'list' ('id', '標題', '日期') VALUES ('1250311705','news2','Saturday 15th of August 2009 04:48:25')
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ''list' ('id', '標題', '日期') VALUES ('1250311705','news2','Saturday 15th of' at line 1
勞煩眾高手幫幫忙吧
--
※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 59.115.193.58
推
08/15 13:21, , 1F
08/15 13:21, 1F
→
08/15 13:54, , 2F
08/15 13:54, 2F
PHP 近期熱門文章
PTT數位生活區 即時熱門文章