I'm trying to implement the Gigya module on a site that is using a multi-step registration form, using the Multi-Step Registration module and the Profile2 module. The second page of the form as fields that aren't available from Gigya's user object that need to be filled out. I'm trying to figure out a way to direct the user to the second page of the form from the modal that pops up to gather information on the first page of the form (most of which is automatically filled in for them, so they just need to agree to terms and then click okay).

Can anyone offer any guidance in how to get the gigya form to either load the second page in the modal or to direct the site to the second page after submitting data in the modal? Using a redirect doesn't work because the second page of the form needs information from the first page of the form (from the form_state variable, I believe) or else it throws a 403 error.

If there isn't a way of accomplishing this, does anyone have any suggestions for the best way to create a similar user flow that's social-login-specific?

Thank you!

Comments

gambaweb’s picture

On social registration Gigya Drupal module basically submit the drupal user_register_form (https://api.drupal.org/api/drupal/modules%21user%21user.module/function/...)
we provide hook_gigya_create_user_alter (please see the gigya.api.php file for an example) there you can alter the form_state and add/fill in info according to the gigya user object (http://developers.gigya.com/020_Client_API/010_Socialize/010_Objects/Use...)

emclaughlin’s picture

Thanks for your response! The problem is that this form isn't part of the user_register_form, it's a profile2 form that's being added to the registration flow via the Multi-Step Registration module. There's information on the form that needs to be collected that won't be found in the user object, in order to provide the user with the best site experience.

Adding a form redirect to that page doesn't work because the form_state isn't included in the redirect, and it appears as though the Multi-Step Registration module uses some of the hidden form_state values to validate that the user is able to access the form page or something.

Is this all making sense?