Adding days to a date
Posted: Fri Feb 15, 2008 4:45 pm
I have a variable, $IssuedDate that is in m/d/Y format. (The users selects the issued date from a pop-up calender). I need to add 7 days to that date as a new variable, $DateDue. I'm not sure how to do that. Note it is not necessary to verify if any of the dates, issued or due, fall on a Saturday, Sunday or holiday and they are allowed to pick an issue date in the past, even if that results in the due date being in the past.
On a different form is where the variables are used.
Thanks in advance
Code: Select all
<INPUT maxLength=10 name=IssueDate size=10 readonly = yes value=
<?
if (isset($_POST['IssueDate'])) {
echo date("m/d/Y",strtotime($_POST['IssueDate']));
} else {
echo date("m/d/Y");
}
?>Code: Select all
$IssueDate = ($_POST['IssueDate']);