MyBB Community Forums

Full Version: Enter certain code during registration to join a specific group?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
i was wondering if there was a way to add a field in the registration to request a "promo code"? And then the code will add them into the corresponding group.

For example, if I gave my Twitter, Facebook, and MySpace followers a code for different groups at the registration, how would I add the field, and then make MyBB understand what each code means and what to do.

Andrew
Go to: http://yourdomain.com/admin/index.php?mo...action=add

Replace yourdomain.com with your own domain name, and add an Profile Field, select "Yes" in all radio options except "Hide on Profile?"

Next you have to do is to add a variable inside the postbit_author_user template, if you want to show the "Code" on Postbit;

Go to: http://yourdomain.com/admin/index.php?mo...&expand=12

Again, replace the yourdomain.com with your own domain name, and add the following add the bottom of all code inside that template;

<br />Your Code:&nbsp;{$post['fidX']}

Replace X with the order ID of the newly created Profile Field.

That's it.
if i understand well, he wants to insert them in certain group after registration depending on the registration coupon.

A custom plugin needs to be made that is hooked to the registration page. It would do the trick.