我想发布一些数据到php,但我无法发送任何东西,看看问题出在哪里。代码对我来说看起来很好。换句话说,我不能达到if statement.Codes;无法发布数据到PHP
<form method="post" action="home.php" name="home" id="home">
<label for="in_come">enter something: </label><input type="text" name="in_come" id="in_come" /><br/>
<?php
echo "outside if";
if(isset($_POST['in_come']))
{
echo "inside if";
$income = $_POST['in_come'];
$registerquery = mysql_query("INSERT INTO income (income) VALUES ('".$in_come."')");
if ($registerquery)
{
echo "sended";
}
}
?>
您的代码格式不正确。突出显示所有代码和ctrl-k使其成为代码块或使用“{}”按钮。我为你修好了。 –
谢谢。我想在尝试发送代码时,我无意中删除了一些东西 – user893970
是echo“outside if”;加工? – Phphelp