Support

Home Forums Event Espresso Premium User registration (wp integration) on form submission

User registration (wp integration) on form submission

Posted: March 15, 2014 at 3:36 pm


andrea k

March 15, 2014 at 3:36 pm

I am trying to use this: https://gist.github.com/Apina/5576163 from this thread: https://eventespresso.com/topic/event-sign-up-creating-a-user-in-wp-user-or-members/

But there’s no current user verification check. So if I register with an existing email, it’ll let me register even though there’s already a user with that email address. And since it’s assigning that email as the username that obviously causes issues.

If I go to the default WP Login, it does that verification check so I can’t register with an existing email.

Is there any quick work around for the above code because I would prefer that automatic registration at the end vs. required a registration prior to signing up for events.


Dean

March 17, 2014 at 3:11 am

Hi Andrea,

To clarify this “So if I register with an existing email, it’ll let me register even though there’s already a user with that email address” are you referring to the event registration or the site registration?

If the event registration, then no, the script is not intended to block people from registering for events.

If site registration, there is verification in place. It checks via the username (email) and if it does not exist it creates a user.

I do see what you mean though about the username. I have made a modified version here that checks via the email rather than username. https://gist.github.com/Apina/9596012


RJG

March 17, 2014 at 6:10 am

Hello Dean,

is it possible to check both? Most registration forms should check whether the username exists and/or whether the email exists, no?


Dean

March 17, 2014 at 6:34 am

@Riffard,

The user creation system already checks the username so it is in built. That’s why if you look at the code on the gist it does a check for any errors (mainly the username in existence) and if so it doesnt do anything.


RJG

March 17, 2014 at 8:51 am

Is this EE4 compatible?


Sidney Harrell

March 17, 2014 at 9:49 am

No. Since EE4 is a complete rewrite from the ground up, none of the add-ons or custom code that was developed for EE3 will be compatible. We will be rewriting all the add-ons to be EE4 compatible, and rewriting custom code like this will need to be prioritized depending on how many customers are requesting it, etc. If you would like to raise the priority of it by sponsoring the rewriting, either through the Event Espresso development team, or through one of our recommended pro developers.


RJG

March 17, 2014 at 1:10 pm

What is the cost associated with sponsoring a plugin or feature and if I sponsor it, does it become mine and mine only or else?


andrea k

March 17, 2014 at 1:30 pm

Yes, that’s what needed to get updated, so now if someone already has an email address, it will not sign them up a new account.

A few things though:

1) The email that gets sent lists the email address as the username login. This is incorrect, if you try to use the email address it won’t let you log in. It needs to use the actual username (which should be easy enough to change).

2) The bigger issue(which I’m not sure if I can figure out), is once I log in I don’t see any events associated with that email/username (in the user control panel). I do see that email/username listed in the attendees portion of event espresso though.

3) Finally…since #2 isn’t working, I can’t test this – but if an email already exists, and someone signs up with that email, it will not create an account(since once exists). But will it add those new events once submitted to the existing user account?

Thanks!


Dean

March 18, 2014 at 2:01 am

@Riffard – please keep to one thread if possible – https://eventespresso.com/topic/create-wp-user-with-ee4-event-registration/#post-86606

@andrea

1) Good catch, fixed

2) Surprisingly an easy fix. Please note though that these Gists are intended to be starting points for customers to build on rather than something that will be maintained.

3) No. The user needs to be logged in, with WP User Integration active. Simply providing an email address/username is not sufficient to tie an event to the user.


andrea k

March 18, 2014 at 11:40 am

Thanks for the updates, seems to be working great now. I’ll probably just flush the system registrations when a set of them is over for the year, this way it eliminates someone signing up and already having an account(I’d prefer not to force registration for signups)

Thanks

The support post ‘User registration (wp integration) on form submission’ 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