Jason,
I've inserted the new code and it hasn't worked for me on this occasion - see what I did below:
I entered a new player and left his email blank.
I then entered another player and left his email blank - I then get the following message in my browser - Duplicate entry '' for key 'email'.
Below is my updated validation code:
<?php
if (($_SERVER["REQUEST_METHOD"] == "POST") && (isset($_SERVER["HTTP_REFERER"]) && strpos(urldecode($_SERVER["HTTP_REFERER"]), urldecode($_SERVER["SERVER_NAME"].$_SERVER["PHP_SELF"])) > 0) && isset($_POST)) {
$WAFV_Redirect = "";
$_SESSION['WAVT_register_184_Errors'] = "";
if ($WAFV_Redirect == "") {
$WAFV_Redirect = $_SERVER["PHP_SELF"];
}
$WAFV_Errors = "";
$WAFV_Errors .= WAValidateRQ(((isset($_POST["f_name"]))?$_POST["f_name"]:"") . "",false,1);
$WAFV_Errors .= WAValidateEM(((isset($_POST["email"]))?$_POST["email"]:"") . "",false,2);
$WAFV_Errors .= WAValidateUnique("CommSimpleRegister",$CommSimpleRegister,$database_CommSimpleRegister,"test_table","email","',none,''","0","email","',none,''","".(((isset($_POST["email"]) && $_POST["email"] != ""))?$_POST["email"]:"123456789") ."",true,3);
if ($WAFV_Errors != "") {
PostResult($WAFV_Redirect,$WAFV_Errors,"register_184");
}
}
?>