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

Confusing Functions
So, I've been reading up on Functions and I like them! However, I need some help using variables in

UL and LI Add Form
The idea I want here is when the user click on a character name from the drop down select bar at the

unoconv doc convert to pdf code prob
PHP/5.3.1

Hi. I am trying to use this code to convert docs to .pdf utilizing unoconv. Howe

Help with search.php
Hello All

I need the search engine on a site I am building at the moment to display the searc

batch file not building to webapps folder
Hello. I just started running Vista :P and can't seem to get my projects deployed. I found out how

login page does not execute a else statement
I've created a login page using sessions.
When an incorrect user name or password is entered then

Cloud Computing?
Hello,

I was wondering if anyone could help explain this term to me. I'm starting to hear it

is this the proper use of mysql_real_escape_string() to prevent sql injections?
i was wondering is this the proper use of mysql_real_escape_string() to prevent sql injections? any

Text Not Displaying Correctly With PHP:GD
I recently moved servers and since then I have noticed that one line of text is showing weirdly.

DateTimeZone::listIdentifiers headache
http://php.net/manual/en/datetimezone.listidentifiers.php


So the documentation states tha

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