Support

Home Forums Event Espresso Premium Create users for each of the registrants

Create users for each of the registrants

Posted: February 2, 2017 at 5:53 am


Airborne Experience

February 2, 2017 at 5:53 am

Hi,

I’m using the WP Users integration which works well in that it creates a user with the registrant’s details.

I’d like to make additional users for each of the additional registrant’s that the user has purchased tickets for.

For example Bob Smith registers 4 tickets. I’d like to create 4 users.

What hook can I tap into to create this?

Is there documentation for all the available hooks and filter?

How do you gain access to the Event Espresso object or are their a few that provide access to core functionality?

Do you guys have a listing of available methods.

Will these users be able to amend their details via the link on their profile?

If not, is there a link I can use to add it in?

Thanks for the help ๐Ÿ™‚


Josh

  • Support Staff

February 2, 2017 at 8:24 am

Hi there,

There’s a code example in our code snippet library that shows how to modify the WP User integration add-on so it adds a user account for every registration in a transaction. Here’s a link to that snippet:

https://github.com/eventespresso/ee-code-snippet-library/blob/master/addons/eea-wp-user/jf_ee_process_multi_wpuser_for_attendees.php


Airborne Experience

February 2, 2017 at 11:46 am

Thanks Josh, I’ll give that a try and let you know how it goes.

Your snippet library is gold. Thats going to speed things up on my end.


Airborne Experience

February 2, 2017 at 4:42 pm

Hi Josh,

So the snippet is not working on my end. The event transaction takes place but the only user created is the primary registrant and not the additional ones.

Any ideas on what the issue is?


Josh

  • Support Staff

February 2, 2017 at 5:09 pm

Were you logged into the website when you tested the code?


Josh

  • Support Staff

February 2, 2017 at 5:22 pm

Another guess: Did you add the code to a theme’s functions.php file or into its own plugin? If it was added to a theme’s functions.php file, the code will not execute (it’s too late at that point). You’ll need to make sure you load the code via its own WP plugin. See also:

https://eventespresso.com/wiki/create-site-specific-plugin-wordpress-site/


Airborne Experience

February 2, 2017 at 5:42 pm

Thanks Josh!

That got me sorted. I had it in the functions.php file and moved it to a must use plugin.

Much appreciated ๐Ÿ™‚

The support post ‘Create users for each of the registrants’ is closed to new replies.

Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.

Event Espresso