php中向mysql插入数据

1 $sql='insert into news(title,subtitle,source,publishtime,content,image,author) values("'.unicode_decode(strval($newsTitle),"utf-8").'","","'.unicode_decode(strval($newsSource),"utf-8").'","2012-12-12 10:10","","","")';
2 
3  
4 if($conn->multi_query($sql)){
5    echo "success";
6   }else{
7    echo "insert failure";
8   } 

 

posted @ 2015-01-06 17:43  逸乐太子  阅读(162)  评论(0编辑  收藏  举报