date time php
$today = date("F j, Y, g:i a"); // March 10, 2001, 5:16 pm
$today = date("m.d.y"); // 03.10.01
$today = date("j, n, Y"); // 10, 3, 2001
$today = date("Ymd"); // 20010310
$today = date('h-i-s, j-m-y, it is w Day'); // 05-16-18, 10-03-01, 1631 1618 6 Satpm01
$today = date('\i\t \i\s \t\h\e jS \d\a\y.'); // it is the 10th day.
$today = date("D M j G:i:s T Y"); // Sat Mar 10 17:16:18 MST 2001
$today = date('H:m:s \m \i\s\ \m\o\n\t\h'); // 17:03:18 m is month
$today = date("H:i:s"); // 17:16:18
$today = date("Y-m-d H:i:s"); // 2001-03-10 17:16:18 (the MySQL DATETIME format)
// 1. create a date instance
$date = new DateTime;
// 2. set the date using the setDate(year, month, date) method on the
// $date instance
$date->setDate(1999,02,19);
Also in PHP:
- clear laravel storage cache
- Laravel Validation check array size min and max
- ALTER table migrations
- delete file using php
- fetch last inserted data with record in php codeingniter
- <?php echo do_shortcode(' '); ?> with variable
- drupal 8 enable twig debug
- PHP Password Generator
- check if front page wordpress
- convert date to times php
- 4random numbers php
- 500 server error in laravel
- displaying current date in php
- cache clear command in larvel
- drupal 8 user_load
- contains the symbol php
- create array and remove duplicates php
- date + 14 days php
- create new laravel project composer
- change php format time
- add seconds to datetime php
- eliminate duplicate values from associative array phph
- doctrine orm get all
- disable timestamps for a table