Venkok Posted June 9, 2020 Share Posted June 9, 2020 Hello! I stuck into this question, please help me to solve it: Rewrite the gender conditional in handle_form.php (Script 2.4) as one conditional instead of two nested ones. Hint: You’ll need to use the AND operator. Link to comment Share on other sites More sharing options...
Larry Posted June 10, 2020 Share Posted June 10, 2020 Sure thing! I answer what I was thinking in this thread: But if you want another hint before you see the answer, there's an outer conditional--isset()--and then an inner conditional--on gender. To make this one conditional instead of two nested ones, each condition must represent both of those tests (the original outer condition plus an original inner condition). Link to comment Share on other sites More sharing options...
Venkok Posted June 11, 2020 Author Share Posted June 11, 2020 After your new hint, I immediately came up with the solution, which now seems so obvious! Thank you! Link to comment Share on other sites More sharing options...
Larry Posted June 12, 2020 Share Posted June 12, 2020 Awesome! You're most welcome. Link to comment Share on other sites More sharing options...
Recommended Posts