title: PHP check if 1 day passed
body: <blockquote>
    <p><strong>Possible Duplicate:</strong><br>
    <a href="https://stackoverflow.com/questions/4421076/phpfind-day-difference-between-two-dateymdhis-reture">PHP:find day difference between two date(&ldquo;YmdHis&rdquo;) reture</a>  </p>
  </blockquote>
  
  
  
  <p>What I want to do is to get day from database, current date. And check if difference between them > 1 day:</p>
  
  <pre><code>$curdate= date("Y-m-d H:i:s");
  </code></pre>
  
  <p><code>$dbdate</code> is value stored in datetime format in db. </p>
  
  <pre><code>$dif=$curdate-dbdate;
  </code></pre>
  
  <p>How to check if <code>$dif&gt;1 day</code> ??</p>