miniBB ® miniBB®
miniBB Support Forums
 | Forums | Register | Reply | Search | Statistics | Manual |
Specific miniBB Support Forums / Specific /   

Check user_regdate

Author Guest
#1 | Posted: 26 Jan 2012 03:24 
Hey guys!

Is it possible to disable a user if the date the user is logging in is 1 year from the user_regdate in the users table in the database?

if (user_regdate+1year => user_regdate)
// don't login
} else
// login

I'm making a forum where the user has to buy access before being able to access the forumarea.. and it has to make the check upon registration..

Is it possible?

Author Paul
Lead Developer
#2 | Posted: 26 Jan 2012 11:27 
Is it possible?

But I'm not sure how paid membership may be related to this feature. It's achieved different way. Since each payment system has its own payment verification methods, the solution is different for each of such case.

Author Guest
#3 | Posted: 26 Jan 2012 11:41 
To be honest i don't get the way MiniBB is coded.

The payment part is made, the only thing i have to make is the part where the user_regdate is checked uppon login..

Author Paul
Lead Developer
#4 | Posted: 26 Jan 2012 12:29 
You don't have to check user_regdate. Add a new field to miniBB users table, indicating the date of last payment. Add this field's value to bb_cookie.php. When user is logged in, the value from bb_cookie.php will be available in bb_plugins.php. Code the condition in bb_plugins.php to make all forums opened for the logged user, until his payment date doesn't exceed the limit. You can do the same with user_regdate as well.

Specific miniBB Support Forums / Specific / Check user_regdate Top

Your Reply Click this icon to move up to the quoted message

 Short link for this topic:

Only registered users are allowed to post here. Please, enter your username/password details upon posting a message, or register first.

Before posting, make sure your message is compliant with our forum posting rules. If not, it may be locked or deleted with no explanation.
miniBB Support Forums Powered by Forum Software miniBB ® Features  Requirements  Demo  Download  Showcase  Gallery of Arts
Compiler  Premium Extensions  Premium Support  License  Contacts
Get the Captcha add-on: protect your miniBB-forums from the automated spam and flood.
Captcha Addon for miniBB