An example plugin that shows how to modify registration
Hi guys. Looking to request an example plugin that will show me how to add questions to the registration and process their results. I want to try and hook into the registration of a new user and automatically register them to a private gameserver, which is what the forum is for. I want their MyBB account to be automatically associated with this account, and I have the registration to the game down solid... I just cannot for the life of me understand how I'm supposed to add fields to the registration page and then get information back from those fields after registration is complete.

In particular I'd like to add a custom username field, as MyBB and the game have different requirements for usernames (the game only permits lowercase usernames up to a certain length etc) but I'd also like to be able to take the user's username and email from registration and put them into the game too. I've looked at the member.php file and got even more confused than when I started. Please send help, or coffee, or both.

Check this out as that's the array that will eventually be inserted into the database with user info, so I'd assume you need to edit that in someway/add elements to it. Haven't actually played with registration much myself but that's where the vanilla registration is handled. As far as displaying the fields your plugin will probably need to hook into register.php somewhere and add its own fields.

Might work on an example if I get some free time in the future, but try checking out other plugins that add custom registration fields, they're a live example of what you want!

Holler if you have more questions
My Plugins: [1.8]|[1.6]

** Selling custom plugin that enables Bitcoin payments. PM me if interested in purchasing! **

Forum Jump:

Users browsing this thread: 1 Guest(s)