hello all 
I know how to check one field and a few fields, an make sure there filled in.
However I'm designing a 6 step form that has 69 fields in the first step, so using above way is going get long winded fast.
Usually I would do something like below;
I've never had the need to do this to such a large scale before.
I am using below coding instead of manually setting each var.
The coding works as I wish it to, if the field related to $ffirstname is empty, the form not process. I'm just thinking there is got to be something so simple to add to this that allow me to make sure all fields have a actual value and are not blank.
any help would be greatly appreciated.
do have a feeling that when I see a solution I'm going have a homer simpson DOH! moment but head is done in right now designing this lol

I know how to check one field and a few fields, an make sure there filled in.
PHP Code:
if ( $var1 == "" || $var2 == "" ) { send back an try again stuff }
Usually I would do something like below;
PHP Code:
$chiBran = $_POST['childBranch'];
$chiMainid = $_POST['childID'];
$buttype = $_POST['confirm'];
if ( $chiBran == "" || $chiMainid == "" ) { send back an try again stuff }
I am using below coding instead of manually setting each var.
PHP Code:
foreach ($_POST as $field => $value)
{
if ( $ffirstName == "" )
{
unset($_GET['do']);
$mess = "Required information is missing, please try again.";
include("register-step1.php");
exit();
}
}
any help would be greatly appreciated.
do have a feeling that when I see a solution I'm going have a homer simpson DOH! moment but head is done in right now designing this lol
Comment