This topic is locked

Adding Days To A Date

5/19/2013 12:55:57 PM
PHPRunner General questions
D
dustinforehand author

Was wondering if it is possible to add days to a date.
I have two fields Timestamp and Schedule date
Is there a way that the default value to schedule date can be the timestamp date + 5 days. Or a way to + 5 business days.
Right now I have timestamp default value set to now(). and a message to tell the user that the schedule date must be 5 business days after the timestamp

A
Athlon 5/31/2013



Was wondering if it is possible to add days to a date.
I have two fields Timestamp and Schedule date
Is there a way that the default value to schedule date can be the timestamp date + 5 days. Or a way to + 5 business days.
Right now I have timestamp default value set to now(). and a message to tell the user that the schedule date must be 5 business days after the timestamp


YOu could change the following to fit - is set to 3 hours.
//** Access denied until time has lapsed since last edits by staff
$exp_date = $values["Date_Last_Modified"];

$todays_date = Now();
$today = strtotime($todays_date);

$expiration_date = strtotime($exp_date);
if ($expiration_date+60
180 > $today) {

header("Location: wait.htm");

exit();;

} else {

echo "Edits allowed";
}
Mike.