我有一个类似戳的应用程序,它似乎没有插入到“戳”表中。
尽管我的代码看起来和看起来都很好,但它似乎没有显示任何迹象?有任何想法吗?
if (@$_POST['poke']) {
$check_if_poked = mysql_query("SELECT * FROM pokes WHERE user_to='$username' AND user_from='$added_by'");
$num_poke_found = mysql_num_rows($check_if_poked);
if ($num_poke_found == 1) {
echo "Come on! Give the guy a chance!";
}
else
if ($username == $cookie) {
echo "You cannot Jab yourself.";
}
else
{ $poke_user = mysql_query("INSERT INTO pokes VALUES ('', '$cookie', '$username')") or trigger_error(mysql_error());
echo "$username has been jabbed.";
}
}