<?php
    if($_POST[button]) {
if(!($_POST[textfield] and $_POST[textfield2] and $_POST[textfield3] and $_POST[textfield4] and $_POST[textfield5]))
    {
    echo "<script language='javascript'> alert('输入不允许为空!'); </script>";
}
else
    {
$conn=mysql_connect('localhost','root','root');
mysql_query("use tongxuhua");
$str1="insert into tb_mrbook values($_POST[textfield],$_POST[textfield2],$_POST[textfield3],$_POST[textfield4],$_POST[textfield5])";
$result=mysql_query($str1,$conn);
if($result)
   echo "添加成功,单机<a href=chapter15.php>这里</a>查看";
else
   echo "<script>alert('添加失败');</script>";
}
}

?>
运行的时候怎么都是“添加失败啊”。