add 1 month to date php
<?php
// PHP program to add days to $Date
// Declare a date
$date = "2019-05-10";
// Add days to date and display it
echo date('Y-m-d', strtotime($date. ' + 10 days'));
?> $effectiveDate = date('Y-m-d', strtotime("+3 months", strtotime($effectiveDate)));$time = strtotime("2010.12.11");
$final = date("Y-m-d", strtotime("+1 month", $time));<?php
$months = n; // Here n = …..-2,-1,0,1,2, …..(months to add or subtract)
$years = n; // Here n = …..-2,-1,0,1,2, …..(years to add or subtract)
echo date('Y-m-28', mktime(0, 0, 0, date('m')+$months, 1, date('Y') + $years));
?>
Also in PHP:
- Create cap with php
- blade php code
- To add a new Top-level menu to WordPress Administration, use the add_menu_page() function.
- create new laravel project 8
- create array from string with commas php
- can i back up mysql database from php code?
- cache:clear php artisan
- array_search
- dequeue recaptcha wordpress
- php random string generator
- echo in json format php
- debug native php
- check typeof variable php
- check if the string match in php
- catch an exception within a catch block php
- don't show php errors
- ajax call php
- advantages of php
- calculate total time from start and end datetime in php
- $headder in php
- add one day to given date in php
- Jan 5, 2021 15:37:25 time format php
- check null in_array php
- date time format list php