Error in WA Validations.
Found the reason input not being retained.
<input name="lastname" type="text" size="25" maxlength="60" value="<?php echo(ValidatedField("enquiries","address2")) ?>" />
Should be:
<input name="lastname" type="text" size="25" maxlength="60" value="<?php echo(ValidatedField("enquiries_086","address2")) ?>" />
enquiries_086 stores the session data, not just enquiries.
The validations have a random numeral added to the session data name
I guess it's another bug, see below:
<?php
if (isset($_POST["submit"])) {
$WAFV_Redirect = "enquiries.php";
$_SESSION['WAVT_enquiries_086_Errors'] = "";
if ($WAFV_Redirect == "") {
$WAFV_Redirect = $_SERVER["PHP_SELF"];
}
$WAFV_Errors = "";
$WAFV_Errors .= WAValidateLE(strtolower($_SESSION['captcha_Security_Code_1']) . "",strtolower(((isset($_POST["Security_Code_1"]))?$_POST["Security_Code_1"]:"")) . "",true,2);
$WAFV_Errors .= WAValidateRQ(((isset($_POST["firstname"]))?$_POST["firstname"]:"") . "",false,3);
$WAFV_Errors .= WAValidateRQ(((isset($_POST["lastname"]))?$_POST["lastname"]:"") . "",false,4);
$WAFV_Errors .= WAValidateRQ(((isset($_POST["city"]))?$_POST["city"]:"") . "",false,6);
$WAFV_Errors .= WAValidateRQ(((isset($_POST["state"]))?$_POST["state"]:"") . "",false,7);
$WAFV_Errors .= WAValidateRQ(((isset($_POST["postcode"]))?$_POST["postcode"]:"") . "",false,8);
$WAFV_Errors .= WAValidateRQ(((isset($_POST["country"]))?$_POST["country"]:"") . "",false,9);
$WAFV_Errors .= WAValidateAN(((isset($_POST["telephone"]))?$_POST["telephone"]:"") . "",true,true,true,true,"",true,10);
$WAFV_Errors .= WAValidateAN(((isset($_POST["address"]))?$_POST["address"]:"") . "",true,true,true,true,"",true,11);
$WAFV_Errors .= WAValidateEM(((isset($_POST["email"]))?$_POST["email"]:"") . "",true,12);
$WAFV_Errors .= WAValidateAN(((isset($_POST["message"]))?$_POST["message"]:"") . "",true,true,true,true,"",true,13);
if ($WAFV_Errors != "") {
PostResult($WAFV_Redirect,$WAFV_Errors,"enquiries_086");
}
}
?>