关于PHP与MYSQL连接时的数据传输问题!
<?
if($name){
setcookie("name",$name,time()+3600);
}
?>
<html>
<body>
<?
if($name&&$chat){
$conn=mysql_connect("localhost:3306","root","");
mysql_select_db("tuzi");
$time=time();
$sql="inert into chat(name,puttime,chat) values('$name','$time','$chat')";
mysql_query($sql,$conn);
}
?>
<form method="post" action="put.php">
Name:
<input type="text" name="name" size="15"
<?if($name)echo "value=\"$name\"";?>
>
chat:
<input type="text" name="chat" size="20">
<input type="submit" name="submit" value="OK">
</form>
</body>
</html>
数据无法insert到数据中去为什么啊!救急!!!!谢谢了!