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

Libraries in C++
Hi all,

I have two libraries. one is based targeted on linux platform and uses another li

php mail form text wont appear / javascript included
Guys/gals...

I am running into a problem whereby I have a great piece of javascript code that

Socket Server Response Headers
Earlier I had a post about my Socket Server, I wasn't able to get it to connect, now I can

I

Need help with PHP/MySQL drop down menu
I need help on how I can implement a drop down menu which queries mysql database and output the avai

Automatic Webpage ??
I have a page www.mysite.com/test.php with a
<form>
<textarea name=&q

$_POST
Hi, I have 2 seperate php files, and i want my $_POSt["fname"] To go into both of them, Fo

Query output more than expected
$query=mysql_query("SELECT * FROM players, communities, divisions WHERE dob BETWEEN '{$start_da

help finding hacking loopholes
i was attacked by a redirect php injection

my pc is clean of viruses

so i figure that

Do something every fifth time?
I'm trying to write a loop, but I want it to do something different after every fifth instance. Like

COOIS - Saving Object Overview WIP Status layouts
COOIS - Would like to be able to save the layout of an Object Overview - WIP Status report. There 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