title: Convert date format to dd-mm-yyyy hh:mm:ii (2018-08-05T06:22:30Z) in PHP
body: <p>I have date format like this (2018-08-05T06:22:30Z). I need to convert it to dd-mm-yyyy hh:mm:ii format.</p>
  
  <p>I have tried this so far:</p>
  
  <pre><code>$dt ="2018-08-05T06:22:30Z";
  $dt1 = date('d-m-Y HH:mm:ii', strtotime($dt));
  </code></pre>
  
  <p>Output of above code is <strong>05-08-2018 0202:0808:2222</strong>.</p>
  
  <p>How can I convert it to <code>dd-mm-yyyy hh:mm:ii</code> format?</p>