PDA

View Full Version : HELP -> Setting forward date stamp


trafix
02-06-2004, 09:11 AM
ok i use
$endmonitor= strtotime("now +365 days");
to set a date stamp 1 year for now

question....

how do i set add to a future datestamp

ummm ..... say a user has x to expire in 10 days ... and he wants to extend that for anouther 40 days

what code do i need to add 40 days to the original 10 days making it a total of 50 days before x expires?

is that too confusing...i hope not :)

NTLDR
02-06-2004, 01:14 PM
Ten days from now:


$tendays = time() + (60 * 60 * 24 * 10);


40 day extension:



$fourtydays = $tendays + (60 * 60 * 24 * 40);


I assume thats what you mean.