title: PHP Get Date and Time when a button is clicked and store it in a variable
body: <p>I would love to know if this is possible using PHP. For an instance, I want the current date and time be stored on a variable once I click the submit button. Here is what I have in mind:</p>
  
  <pre><code>&lt;?php
  if ($_POST["submit"] == 'submit')
  //store the variable here
  ?&gt;
  
  &lt;form action ="" method="post"&gt;
  &lt;input type="submit" name="submit"&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p>I am quite new to PHP, hope you guys can help me! cheers.</p>