title: PHP and MySQL WHERE AND
body: <p>I have a form that posts to createcsv.php. The form has two fields <code>"entmonth"</code> and <code>"entyear"</code>. I am having trouble in createcsv.php where <code>"entmonth"</code> pulls correctly, but <code>"entyear"</code> doesn't seem to pull the <code>$_POST['entyear']</code> variable. I have some input and need to know where I have gone wrong in these lines of code.</p>
  
  <pre><code>mysql_connect("$host", "$username", "$password")or die("cannot connect"); 
  mysql_select_db("$db_name")or die("cannot select DB"); 
  $entmonh='$_POST[entmonth]';
  $entyear='$_POST[entyear]';
  $select = "SELECT * FROM POs WHERE entmonth = '$entmonth' AND entyear = '$entyear'";
  </code></pre>