ציטוט:
נכתב במקור על ידי Ron-Pro
PHP קוד:
$email = $_POST['email_address'];
$result = mysql_query("SELECT * FROM `emails` WHERE `email_address`= '$email')") or die(mysql_error());
$search = mysql_num_rows($result);
if ($search == 0)
{
mysql_query("INSERT INTO `emails` (`email_address`) VALUES ('$email')") or die(mysql_error());
echo("<font color=\"red\">האימייל נוסף בהצלחה</font>");
}
else {
echo("<font color=\"red\">אנא בחר אימייל אחר</font>");
}
יש מצב קטן שיש טעויות קטנות אבל לא נראה לי ,כי אני חייב ללכת ועשיתי את זה מהר.
תהנה.
|
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')' at line 1