Skip to content

How to set date in PHP?

<?php
$str = 'Tue Dec 15 2009';
$timestamp = strtotime($str);
echo $timestamp;
//output: 1260831600
?>
See also  How to find unique characters in a string in Java?

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.