Skip to Content Skip to Menu

Simple onAfterUserRegistration bot user plugin

17 years 1 month ago #45881 by quiquedcode
Hi guys
I've been reading the API docs of CB, and I want to create a simple user plugin that allows me to re-POST the registration form (using CURL), but for another site (to duplicate the user in another website)

I just want to make a simple plugin that registers and triggers this event onAfterUserRegistration but the examples contains TABS, etc. which I don't need

Can any1 help me to create this simple plugin ? and how should I loop through all the fields (std. + custom ones) in this plugin ?

Thanks a lot in advance... :blush:

Please Log in or Create an account to join the conversation.

  • nant
  • nant
  • OFFLINE
  • Posts: 12339
  • Thanks: 1467
  • Karma: 877
17 years 1 month ago #45883 by nant
you can also study the hello world plugins to get started...

Please Log in or Create an account to join the conversation.

17 years 1 month ago #45885 by quiquedcode
Replied by quiquedcode on topic Re:Simple onAfterUserRegistration bot user plugin
nant wrote:

you can also study the hello world plugins to get started...


Hi nick, thanks for the prompt reply, but as I wrote in my prev. post, I've checked the helloworld plugins (the 2 I downloaded from this site) but they work and use a new tab

should i erase all the code within the php file and just start the registration of the event ?

I just don't get it, it would be nice 2 have an example of how just to do that, without working with xtra tabs, or parameters I won't need

Please Log in or Create an account to join the conversation.

  • nant
  • nant
  • OFFLINE
  • Posts: 12339
  • Thanks: 1467
  • Karma: 877
17 years 1 month ago #45886 by nant
quiquedcode wrote:

Hi nick, thanks for the prompt reply, but as I wrote in my prev. post, I've checked the helloworld plugins (the 2 I downloaded from this site) but they work and use a new tab


hmmm, sorry - didn't see this in your post (at least not in this thread).

You could also study the autowelcome plugin that basically triggers off similar events and does not display a tab.

Please Log in or Create an account to join the conversation.

17 years 1 month ago #46060 by quiquedcode
Replied by quiquedcode on topic Re:Simple onAfterUserRegistration bot user plugin
Hey Nick
I've seen your plugin, it only registers this event

$_PLUGINS->registerFunction( 'onUserActive', 'awUserActivated', 'plug_cbautowelcomeclass' );

I guess onUserActive is the event that fires when user clicks the link he got in the registration email, right?

Well, I'd like to know now which variable holds all the fields of my custom register form, or which way to get the list of fields user filled in the form, so I can send these fields using CURL to another server...

:huh: :dry: Thanks a lot in advance. Hope your help

Please Log in or Create an account to join the conversation.

  • nant
  • nant
  • OFFLINE
  • Posts: 12339
  • Thanks: 1467
  • Karma: 877
17 years 1 month ago #46065 by nant
quiquedcode wrote:

Hey Nick
I've seen your plugin, it only registers this event

$_PLUGINS->registerFunction( 'onUserActive', 'awUserActivated', 'plug_cbautowelcomeclass' );

I guess onUserActive is the event that fires when user clicks the link he got in the registration email, right?


actually, this trigger fires when a new user is first activated (the how - depends on the workflow that is active in CB).

Well, I'd like to know now which variable holds all the fields of my custom register form, or which way to get the list of fields user filled in the form, so I can send these fields using CURL to another server...

:huh: :dry: Thanks a lot in advance. Hope your help


Like the helloworld example, $user holds all values you want.

Please Log in or Create an account to join the conversation.

Moderators: beatnantkrileon
Powered by Kunena Forum