Posted: May 16, 2017 at 4:11 pm
|
Hello, We have the ability in EE4 to set a specific page for the account creation when we force users to be logged in to be able to register to an event. Please see screenshots of the settings I talk about in EE4 backend [screen 1]: https://drive.google.com/open?id=0B4-hsazMWUExX0VaSE9lLXpBODQ Here is the screen that appears when in front-end I click on register to the event although I’m not logged in [screen 2]: https://drive.google.com/open?id=0B4-hsazMWUExODdQQUoyVmdJakk Then, I click on “register for an account here” and I register through the page I set up in the EE4 settings shown before. Once I’m connected, I was excpected to be directed to the page that allow me to go on my registration to the event. The step 2 of the event registration, this one [screen 3]: https://drive.google.com/open?id=0B4-hsazMWUExSXc4RlpUT3ZBa0k This is the page on which I’m redirected when I directly login when EE4 offer me to do so on the [screen 2]: https://drive.google.com/open?id=0B4-hsazMWUExODdQQUoyVmdJakk But it is not the case, I stay on the login page, logged in. Do you know how I could do to redirect my users to the step of the event registration once connected through the page I setup in the backend settings “Registration page URL (if different from default Worpress Registration)? Thanks a lot |
Hi there, I’m guessing based on the page name you showed in your screenshot that you are using the BuddyPress registration form on that page? Basically, EE has nothing to do with the registration of the user, it simply provides an option for you to change the default link when the user clicks that they are taken to the page. That page is not a part of Event Espresso so how would it know to redirect back to the event checkout after registration? Your BuddyPress registration page needs to redirect back to /registration-checkout/ after the user has been registered which should then continue with the registration. You’ll need some custom development for that and will also need some way to determine if the user came from an EE registration or another part of the site (you don’t want to redirect a user to the EE checkout if they aren’t registering from the checkout page). If you are using BuddyPress take a look into the https://buddypress.org/support/topic/how-to-redirect-after-registration/ To be clear, most of what you are trying to do here is outside the scope of EE support. |
|
|
Hi Tony, |
You could use the https://developer.wordpress.org/reference/functions/wp_get_referer/ |
|
There are lots of different options for what you’re trying to do. The way I would do it would be to use:
To see if the current user had an EE checkout session, you do this by checking Then id they did, log the newly created user into the site and redirect them back to the registration checkout page. The instance of EE_Checkout will have all of the details you need to direct the user back to their cart session. |
|
I put together a working example of the above here: https://gist.github.com/Pebblo/8e657cffab1ddd1bd16451fe567c02eb Note this should be considered untested (I’ve done some minimal testing to confirm it does what I was expected but it needs much more) and unsupported but it’s a base for you to work on 🙂 |
|
The support post ‘Account creation when registrating to an event EE4’ 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.