cashflowtips Posted August 30, 2007 Share Posted August 30, 2007 Can anyone teach me how to do the time counter? Situation : user enter the number of days he want, php code will save the number into database and from it, the number will decrease each day until it finally reach the time set by the user? Thanks for any help! Quote Link to comment https://forums.phpfreaks.com/topic/67284-time-counter/ Share on other sites More sharing options...
Psycho Posted August 30, 2007 Share Posted August 30, 2007 I would take the number of days entered by the user and add it to the current date. Then save that timestamp into the database. Now any time the user access a page needing the number of days left, just calculate the number of days from the current date to the target date. Quote Link to comment https://forums.phpfreaks.com/topic/67284-time-counter/#findComment-337548 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.