Forum Moderators: coopster

Message Too Old, No Replies

php time() issue

how to set time for one month

         

tabish

8:05 am on Jul 13, 2006 (gmt 0)

10+ Year Member



I have a PHP Cache script in which the time for cache period is given like this:

$cachetime = 1080 * 60; // 1 week

Now what if i want to make it for one Month? what will be the calulation?

Regards

omoutop

8:26 am on Jul 13, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



i believe that in your example $cachetime = 10080 * 60; // 1 week

this comes from 7 * 24 * 24 *60 (days,hours,mins,secs)

so if you want a month period just do 30*24*24*60 or use the date() funtion to find the exact number fo days in your current month