title: how to stop php countdown timer at zero
body: <p>I want to stop my php countdown timer to stop at 00:00:00:00</p>
  
  <p>here is my code </p>
  
  <pre><code>$due_date = strtotime('July 4, 2014 10:33 PM');
  $rem = $due_date - time();
  $day = floor($rem / 86400);
  $hr  = floor(($rem % 86400) / 3600);
  $min = floor(($rem % 3600) / 60);
  $sec = ($rem % 60);
  echo "$day Days $hr Hours $min Minutes $sec Seconds Remaining...";
  </code></pre>
  
  <p>but it runs further to -1 and so on in minus values.</p>
  
  <p>i dont want it, I want to stop it at zeros. So I can echo my any msg when it stops at zero.
  any idea how to do it?</p>
  
  <p>many thanks in advance.</p>