title: warning mktime() expects parameter 4 to be long string
body: <pre><code>  warning mktime() expects parameter 4 to be long string
  </code></pre>
  
  <p>This is the error I am getting when I try to store Date of birth into a mysql database.</p>
  
  <p><strong>Here is the HTML code:</strong></p>
  
  <pre><code> &lt;!doctype html&gt;
      &lt;html&gt;
      &lt;head&gt;
      &lt;meta charset="utf-8"&gt;
      &lt;title&gt;Registration&lt;/title&gt;
      &lt;link href='http://fonts.googleapis.com/css?family=Josefin+Sans' rel='stylesheet' type='text/css'&gt;
      &lt;style&gt;
      #container{
      width:350px;
      height:auto;
      float:left;
      font-family: 'Josefin Sans', sans-serif;
      color:#82ABEA;
      }
      label{
      display:block;
      margin-bottom:5px;
      }
      fieldset{
      border-color:#82ABEA;
      }
      button{
      background-color:#900;
      color:#FFF;
      border:none;
      box-shadow:none;
      width:80px;
      height:30px;
      }
      &lt;/style&gt;
      &lt;/head&gt;
  
      &lt;body&gt;
      &lt;div id="container"&gt;
      &lt;form method="post" action="save_reg.php"&gt;
      &lt;fieldset&gt;
      &lt;legend&gt;&lt;b&gt;Register Here&lt;/b&gt;&lt;/legend&gt;
  
  
      &lt;label&gt;Date Of Birth&lt;/label&gt;
      &lt;select name="db"&gt;
      &lt;option selected&gt;Month&lt;/option&gt;
      &lt;option&gt;January&lt;/option&gt;
      &lt;option&gt;February&lt;/option&gt;
      &lt;option&gt;March&lt;/option&gt;
      &lt;option&gt;April&lt;/option&gt;
      &lt;option&gt;May&lt;/option&gt;
      &lt;option&gt;June&lt;/option&gt;
      &lt;option&gt;July&lt;/option&gt;
      &lt;option&gt;August&lt;/option&gt;
      &lt;option&gt;September&lt;/option&gt;
      &lt;option&gt;October&lt;/option&gt;
      &lt;option&gt;November&lt;/option&gt;
      &lt;option&gt;December&lt;/option&gt;
  
      &lt;/select&gt;
      &lt;select name="dbd"&gt;
      &lt;option selected&gt;Day&lt;/option&gt;
      &lt;option&gt;01&lt;/option&gt;
      &lt;option&gt;02&lt;/option&gt;
      &lt;option&gt;03&lt;/option&gt;
      &lt;option&gt;04&lt;/option&gt;
      &lt;option&gt;05&lt;/option&gt;
      &lt;option&gt;06&lt;/option&gt;
      &lt;option&gt;07&lt;/option&gt;
      &lt;option&gt;08&lt;/option&gt;
      &lt;option&gt;09&lt;/option&gt;
      &lt;option&gt;10&lt;/option&gt;
      &lt;option&gt;11&lt;/option&gt;
      &lt;option&gt;12&lt;/option&gt;
      &lt;/select&gt;
  
      &lt;select name="dby"&gt;
      &lt;option selected&gt;Year&lt;/option&gt;
      &lt;option&gt;2005&lt;/option&gt;
      &lt;option&gt;2006&lt;/option&gt;
      &lt;option&gt;2007&lt;/option&gt;
      &lt;option&gt;2008&lt;/option&gt;
      &lt;option&gt;2009&lt;/option&gt;
      &lt;option&gt;2010&lt;/option&gt;
      &lt;option&gt;2011&lt;/option&gt;
      &lt;option&gt;2012&lt;/option&gt;
      &lt;option&gt;2013&lt;/option&gt;
      &lt;option&gt;2014&lt;/option&gt;
      &lt;option&gt;2015&lt;/option&gt;
      &lt;option&gt;2016&lt;/option&gt;
      &lt;/select&gt;&lt;br/&gt;&lt;br/&gt;
  
      &lt;button&gt;&lt;b&gt;Submit&lt;/b&gt;&lt;/button&gt;
      &lt;/fieldset&gt;
      &lt;/form&gt;
      &lt;/div&gt;
      &lt;/body&gt;
      &lt;/html&gt;
  </code></pre>
  
  <p><strong>And here is The Php code I have used:</strong></p>
  
  <pre><code>&lt;?php 
  $connection = mysqli_connect("localhost" , "root" , "", "register");
  if(mysqli_connect_errno()){
      echo"Connection Failed" . mysqli_connect_errno();
  }else{
  echo "Connection Succesfull";
  }
  
  $db= $_POST['db'];
  $dbd= $_POST['dbd'];
  $dby= $_POST['dby'];
  
  $date = date("Y-m-d", mktime(0,0,0,$db, $dbd, $dby));
  
  $sql = "INSERT INTO register_form(dateb) VALUES('$date')";
  
  if(!mysqli_query($connection, $sql)){
  echo"Data is not saved";
  }else{
  echo $_POST['firstname'] . " " . $_POST['lastname'] . "your data is saved";
  }
  </code></pre>
  
  <p><strong>Can someone please guide me to add date of birth to the database?</strong></p>