解析错误:语法错误,意外的'mysql_query'(T_STRING)in [英] Parse error: syntax error, unexpected 'mysql_query' (T_STRING) in
本文介绍了解析错误:语法错误,意外的'mysql_query'(T_STRING)in的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我是新来的PHP我得到这个错误,同时更新表中的一列
if(isset $ _POST ['approved'])){
$ change =SELECT * FROM`workplan`;
$ forchange = mysql_query($ change);
while($ infoChange = mysql_fetch_array($ forchange)){
$ dep = $ infoChange ['division name']
mysql_query(UPDATE workplan SET status = ['0 '] WHERE month = ['january']);
$ b $ / code $ / pre
我只有一个更新列的状态值从1到0的值从13 colums。解决方案你缺少一个分号:
$ dep = $ infoChange ['分区名称']< - 这里
I am new in php i am getting this error while updating one of the column of the table
if(isset($_POST['approved'])) {
$change="SELECT * FROM `workplan`";
$forchange=mysql_query($change);
while ($infoChange = mysql_fetch_array($forchange)) {
$dep=$infoChange['division name']
mysql_query("UPDATE workplan SET status= ['0'] WHERE month=['january']");
}
}
i only one to update the column of status to the value from 1 to 0 from 13 colums ..
解决方案 You're missing a semi-colon:
$dep=$infoChange['division name'] <--HERE
这篇关于解析错误:语法错误,意外的'mysql_query'(T_STRING)in的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文