Support

Home Forums Event Espresso Premium Integration with S2 Member

Integration with S2 Member

Posted: November 13, 2019 at 7:28 am

Viewing 4 reply threads


Torontot

November 13, 2019 at 7:28 am

When I add a new registrant to an event I used to be able to choose from a list of S2 Member registered members. That functionality doesn’t seem to be there anymore. I was wondering what I have to do to get it back.


Josh

  • Support Staff

November 13, 2019 at 8:18 am

Hi,

Event Espresso 4 and its add-ons do not provide this feature. If I were to guess, maybe a developer added this feature for you? There’s another topic from your account where a question was asked about how to add this:

https://eventespresso.com/topic/override-admin-template/

If a developer added the functionality by adding a custom plugin to the site, then you’d reinstall (if needed) then reactivate that plugin.


Torontot

November 13, 2019 at 2:22 pm

Hi Josh,

Thank you for the quick response!

I took a look at the code and found out that the functionality is actually added through a mu-plugin and the code has not been modified since 2017.
I was wondering if you can confirm if the following hooks are still available in the latest version of event espresso:

  • AHEE__Form_Section_Layout__ee_spco_attendee_information_reg_step_form
  • AHEE__admin_wrapper__template__before_admin_page_content

There may be a problem with these hooks that caused the dropdown to disappear.

Here is the complete code:

add_action( 'AHEE__Form_Section_Layout__ee_spco_attendee_information_reg_step_form', 'my_custom_function' );
function my_custom_function() {
  if( is_admin() ) {
    add_action( 'AHEE__admin_wrapper__template__before_admin_page_content', 'my_custom_function_template_hook' );
  };
}
function my_custom_function_template_hook() {
	?>
 		<div id="UserAutofillSection">
 			<form id="um_form" method="POST">
  			<h2>Select a user to register:</h2>
			<div id="s2_user_id" ><?php wp_dropdown_users(); ?></div>
			<input type="submit" value="submit" id="get_user_data_submit">
			</form>
		</div>
	<?php
}  

Thanks.


Josh

  • Support Staff

November 13, 2019 at 3:31 pm

You could use the
AHEE__EE_SPCO_Reg_Step__display_reg_form__reg_form
instead of the dynamically generated
AHEE__Form_Section_Layout__ee_spco_attendee_information_reg_step_form
hook.

One thing you probably do not need there is the is_admin() check because the AHEE__admin_wrapper__template__before_admin_page_content hook only fires on admin pages.


Torontot

November 14, 2019 at 7:50 am

Awesome! the change from AHEE__Form_Section_Layout__ee_spco_attendee_information_reg_step_form to AHEE__EE_SPCO_Reg_Step__display_reg_form__reg_form actually got the user selection back in the form.

Thank you Josh for your help and support!

Viewing 4 reply threads

The support post ‘Integration with S2 Member’ 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