title: MongoDB & PHP - How do I exclude results from a date range delimited query?
body: <p>Long time peruser, first time question asker ...</p>
  
  <p>Using PHP to query our MongoDB page visit log, I would like to get a set of records between two time periods, but exclude results that have a certain userAgent.  I've figured out the time range but cannot find anywhere that explains the exclude.</p>
  
  <p>Here's what I have for the query so far:</p>
  
  <pre><code>$dateRange = $collection-&gt;find(array("timeStamp" =&gt; array('$gt' =&gt; $start, 
                                                            '$lt' =&gt; $end)));
  </code></pre>
  
  <p>Looking for code to complete the find function to exclude the records with a "userAgent" starting with "ELB"</p>