title: php mysql search by first initial
body: <p>I have a member directory in a mysql database. I want users to be able to search by first initial of first or last name. I currently have code that allows searching by initial but brings up any name that has the letter in it, regardless of whether it is the first letter or not. How do I set this to only return if the first letter of wither name matches that selected?</p>
  
  <pre><code>$sql="SELECT ID, FirstName, LastName FROM stafftest WHERE FirstName LIKE '%" . $letter . "%' OR LastName LIKE '%" . $letter ."%'";
  </code></pre>