Check premium expire


Posted on 16th Feb 2014 07:03 pm by admin

Hi,

I am making a simple file hosting site and want to check if users premium subscriptions have ended or not. In the database i have premium_start ( time() ) and premium_end ( time() ) that represents the start and end date.

Would the following code work to check if an account has expired?
Code: <?php
// check premium expire
if((time() - $member['premium_end']) >= time())
{
// do actions here
}
?>

thanks

No comments posted yet

Your Answer:

Login to answer
165 Like 44 Dislike
Previous forums Next forums
Other forums

Logic question
im wondering what's the best method to do the above list:

it is for alliance @ MMORPG game

PHP switch function help
Hi, I am trying to create a search function for a directory website. On the search function on html

I need help with formatting date from mysql! with php!
Hello guys

*Note: this is a php question not MySQL question, please do not move it to mysql s

Unable to customise toolbar in FCK
PHP mail() with images
I'm trying to get images to send along with my HTML e-mail sent through PHP mail(). I only tried vie

Multiple PHP errors when clicking a link..and..removing a ghost..
Hi - I have 2 problems with a new website - homeswapvacations.com, which I need help solving.

Server side $_SESSION
how does one keep the session completely server side. no cookies to the browser at all. i need this

quick question about System Change Number(SCN) in FlashBack Query topic
i know tht we can get the SCN of the database using flashback concept as follows

SQL>

Error in SQL Syntax HELP!!!
I have this page:

Code: <?php

session_start();

//connect to server and s

Expandable Post Code
Hi,

Hope you can help. Which currently I haven't upgraded to connect to a mysql server, so i

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash