title: Birthday countdown Calculator in PHP
body: <p>I want to develop BirthDay CountDown calculator in <code>PHP</code></p>
  
  <p>User input the date <code>DD-MM-YYYY</code></p>
  
  <p>I have a days differnce calculator, but it calculates the days from between two specified years.</p>
  
  <pre><code>$daysfrom = $_POST['daysfrom'];
  $daysto = $_POST['daysto'];
  echo 'Difference of days B.W &lt;b&gt;' . $daysfrom . '&lt;/b&gt;-&lt;b&gt;'.$daysto.'&lt;/b&gt; are';
      $daysto = strtotime($daysto);
      $daysfrom = strtotime($daysfrom);
      $datediff = $daysto - $daysfrom;
      echo floor($datediff / (60 * 60 * 24));
  </code></pre>
  
  <p>And I have tried this calculate days between birthday.(I know this is not right)</p>
  
  <p>User will input <code>MM-DD-YYYY</code> and it should calculate days between months.</p>
  
  <p><strong>Ex: -</strong> <strong>Input:</strong> <code>13-03-1993</code>
        <strong>Output:</strong> (Assume todays date is <em>10-03-2014</em>), it should display <code>03 Days left</code></p>
  
  <pre><code> if (isset($_POST['daysto'])) {
         $daysto = $_POST['daysto'];
         echo 'Your birthday comes within ';
         $daysto = strtotime($daysto);
         $now = strtotime(date('d-m'));
         $datediff = $daysto - $now;
         echo $datediff / 60 / 60 / 24;
       }
  </code></pre>