PHP数据无法写入mysql

<?phpinclude("conn.php");//连接数据库if(!empty($_POST['sub'])){$gzmbh=$_POST['gzmbh'];$tfx... <?php
include("conn.php"); //连接数据库
if (!empty($_POST['sub'])){
$gzmbh=$_POST['gzmbh'];
$tfxt=$_POST['tfxt'];
$pfl=$_POST['pfl'];
$jdwsycl=$_POST['jdwsycl'];
$cll=$_POST['cll'];
$sql="insert into `12509gzm`(`gzmbh`,`tfxt`,`pfl`,`jdwsycl`,`ccl`) valuses('{$gzmbh}','{$tfxt}','{$pfl}','{$jdwsycl}','{$cll}')";
mysql_query($sql);
}
?>
<center>
<form action="./add.php" method="post" enctype="multipart/form-data">
<table>
<tr><!-- 第一行表头开始 -->
<th>工作面编号</th>
<th>通风系统</th>
<th>配风量</th>
<th>绝对瓦斯涌出量</th>
<th>抽采量</th>
</tr><!-- 第一行表头结束 -->
<tr><!-- 第二行表填写开始内容 -->
<th> <input type="text" name="gzmbh" /> </th>
<th> <input type="text" name="tfxt" value="U型"/> </th>
<th> <input type="text" name="pfl" /> </th>
<th> <input type="text" name="jdwsycl" /> </th>
<th> <input type="text" name="cll" /> </th>
</tr><!-- 第二行表填写内容结束 -->
<tr><!-- 第三行表填写提交按钮开始 -->
<td><input type="reset" /></td>
<td><input type="submit" name="sub" /></td>
</tr><!-- 第三行表填写提交按钮结束 -->
</table><!-- 表格初步完成 -->
</form>
</center>
展开
 我来答
百度网友5c63a230e
2016-10-19 · TA获得超过1464个赞
知道小有建树答主
回答量:1372
采纳率:16%
帮助的人:620万
展开全部
'{$gzmbh}','{$tfxt}','{$pfl}','{$jdwsycl}','{$cll}

php变量,哪个老师教的是这么个写法.
推荐律师服务: 若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询

为你推荐:

下载百度知道APP,抢鲜体验
使用百度知道APP,立即抢鲜体验。你的手机镜头里或许有别人想知道的答案。
扫描二维码下载
×

类别

我们会通过消息、邮箱等方式尽快将举报结果通知您。

说明

0/200

提交
取消

辅 助

模 式