miniBB ® 

miniBB

®
Support Forums
  
 | Start | Register | Search | Statistics | File Bank | Manual |
Custom Tutorials and Modifications miniBB Support Forums / Custom Tutorials and Modifications /  
 

Disable registrations and display a temporary page

 
Author Vishal
Partaker
#1 | Posted: 2 Mar 2009 03:20 
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
Lead Developer 
#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
Partaker
#3 | Posted: 2 Mar 2009 09:24 
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
Lead Developer 
#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
Partaker
#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 Support Forums / Custom Tutorials and Modifications /
 Disable registrations and display a temporary page
 Share Topic's Link

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


  ?
Post as a Guest, leaving the Password field blank. You could also enter a Guest name, if it's not taken by a member yet. Sign-in and post at once, or just sign-in, bypassing the message's text.


Before posting, make sure your message is compliant with forum rules; otherwise it could be locked or removed with no explanation.

 

 
miniBB Support Forums Powered by Forum Software miniBB ® Home  Features  Requirements  Demo  Download  Showcase  Gallery of Arts
Compiler  Premium Extensions  Premium Support  License  Contact Us
Try the Captcha add-on: protect your miniBB-forums from the automated spam and flood.


  ⇑