miniBB ®
 
miniBB Community Forum
 | Forums | File Bank | Sign Up | Reply | Search | Statistics | Manual |
Copyright Removal allowance for miniBB Did you know that you may be allowed to hide miniBB credits and remove miniBB's copyright notice?
Custom Tutorials and Modifications miniBB Community Forum / Custom Tutorials and Modifications /
Short link for this topic:

Disable registrations and display a temporary page

Author Vishal
Forums Member
#1 | Posted: 2 Mar 2009 03:20 | Edited by: Vishal
We can turn off registrations using $enableNewRegistrations, but this removes the registration link as such. Is there a way to disable registrations keeping the registration link intact. But on clicking the Register link, it should display a custom template containing some temporary notice or so.
Author Paul
CEO
#2 | Posted: 2 Mar 2009 04:16
Sorry I didn't understand that.

If registrations are disabled, that means what it means: users won't be able to register. What kind of "notice" do you mean - does it means you still want to allow users to register, but just accepting some disclaimer before? In that case, refer to our "Disclaimer" solution...
Author Vishal
Forums Member
#3 | Posted: 2 Mar 2009 09:24 | Edited by: Vishal
OK I'll try to be more clear. When I disable registrations, the Registration link will be there, but when users click on the registration link, it should only display a custom page containing information that the registrations are disabled at the moment and reason if any or any temporary notice. That's all.
Author Paul
CEO
#4 | Posted: 3 Mar 2009 04:48
As always, it's possible to achieve adding an interuption to bb_plugins.php (preferrably at the top of that file, before Captcha etc.):

if($action=='register' or $action=='registernew'){
$enableNewRegistrations=FALSE;
echo load_header();
echo ParseTpl(makeUp('registration_disabled'));
$endtime=get_microtime();
$totaltime=sprintf ("%01.3f", ($endtime-$starttime));
if(isset($includeFooter) and $includeFooter!='') include($includeFooter); else echo ParseTpl(makeUp('main_footer'));
exit;
}

Then under templates/registration_disabled.html put any HTML and text regarding disabled registrations.
Author Vishal
Forums Member
#5 | Posted: 3 Mar 2009 04:56
Thanks Paul! I'll try this out and let you know.

Regards,

Vishal
Custom Tutorials and Modifications miniBB Community Forum / Custom Tutorials and Modifications / Disable registrations and display a temporary page Top
Your Reply Click this icon to move up to the quoted message

» Username  » Password 
You are welcome to post anonymously by entering a nickname with no password (if that nickname has not been taken by another member) or by leaving both fields empty. If you have a forums membership account, you can also sign in from this page without posting a message, or sign in and post at once.


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 Community Forum Powered by Free Forum Software miniBB ® Features  Requirements  Demo  Download  Showcase  Gallery of Arts
Compiler  Premium Extensions  Premium Support  License  Contacts