What do you want to save?
Add Code snippet
New code examples
-
Other 2021-10-03 12:03:10
how to get date difference in codeigniter
$date1 = date("Y-m-d",strtotime($_POST['customer_birth'])); $date2 = date("Y-m-d",strtotime($_POST['customer_marriage'])); $diff = abs(strtotime($date2) - strtotime($date1)); $years = floor($diff / (365*60*60*24)); $months = floor(($... Add solution -
PHP 2021-09-30 01:29:02
how to calculate days difference between two dates in php
//get Date diff as intervals $d1 = new DateTime("2018-01-10 00:00:00"); $d2 = new DateTime("2019-05-18 01:23:45"); $interval = $d1->diff($d2); $diffInSeconds = $interval->s; //45 $diffInMinutes = $interval->i; //23 $diffInHou... Add solution -
PHP 2021-09-29 09:40:02
php date format dd/mm/yyyy
date("d/m/Y", strtotime($str)); Add solution