If statement checking for gender
<p>I am having trouble with this simple processing for a form in PHP.</p>

<p>My variables are:</p>

<pre><code> &lt;?php
$first = $_POST['first'];
$last = $_POST['last'];
$gender = $_POST['gender'];
?&gt;  

&lt;?php
if($_POST['submit'] == "submit")
{
$errorMessage = " ";
if(empty($_POST['$first'])) {
    $errorMessage .= "&lt;li&gt;You forgot to enter your first name!&lt;/li&gt;";
}
if(empty($_POST['$last'])){
    $errorMessage .= "&lt;li&gt;You forgot to enter your last name!&lt;/li&gt;";
}
if(isset($_POST['$gender'] == 'Male'))
    echo '&lt;p&gt;&lt;b&gt;Hello, Mr ".$first."\\".$last." welcome to this weeks lesson on        PHP     programming!&lt;/b&gt;&lt;/p&gt;';
}else {
    echo '&lt;p&gt;&lt;b&gt;Hello Ms. ".$first."\\".$last." welcome to this weeks lesson on PHP programming!&lt;/b&gt;&lt;/p&gt;';
}

 ?&gt;
</code></pre>

<p>I am trying to check if the user selected Male or Female in my form. Whichever they selected, I need to echo a statement with Mr. or Ms. followed by their first and last name, welcome to this weeks lesson on PHP programming.  </p>

<p>I am pulling the <code>$gender</code> from a radio selection.  I keep getting an error in the third if statement.  I could really use someones help with this one. Thank you in advance.</p>
