most likely it is failing vlaidation
to help troubleshoot, edit the following code on the thank you page:
if ($WAFV_Errors != "") {
PostResult($WAFV_Redirect,$WAFV_Errors,"thankyou");
}
to:
if ($WAFV_Errors != "") {
die($WAFV_Errors);
PostResult($WAFV_Redirect,$WAFV_Errors,"thankyou");
}
this will help us see what validation is failing.
post back the result and fresh set of the pages, instead of converting the pages to text files, please leave them as php files.