I am trying the following, but my page will not load. It is fine if i take the IF. ELSEIF and ELSE out of the containing IF:
$feet = $inches = "";
if ($_SERVER["REQUEST_METHOD"] == "POST") {
$feet = $_POST["feet"];
$inches = $_POST["inches"];
if(empty($inches)) {
$inchesErr = "Enter Inches"
}
elseif(empty($feet)) {
$feetErr = "Enter Feet"
}
else {
echo $feet;
echo $inches;
}
}
I am sure i am missing something obvious, but I cant see what...And, annoyingly my host has php errors and warning turned off...
Any help would be much appreciated.
Aucun commentaire:
Enregistrer un commentaire