Hello, i was wondering how can i add and if condition. I am pretty sure there should be a condition for that just couldn't figure out, here's example:
if ($age <= 18) {
echo 'You are a little wannabe get out of this site now!';
}
else {
echo "<p>Thank you, <b>$name</b>, for the following comments:<br /> <tt>$comments</tt></p> <p>We will reply to you at <i>$email</i>.</p>\n";
}
Now this works well but if i want to add and and if condition like if the gender chosen on html form was F it would say "You are a little wannebe and a girl, get out of this site now!", i tried following:
if ($age <= 18 && $gender = F)...
if ($age <= 18) {etcetc}
elseif($gender = F) {etcetc}
and i also tried if condition inside of
if ($age <= 18) {
if($gender = F) {etcetc}
}
What is my mistake? How do i do that? Thanks from now.