How to render a user register form for a Profile2 type Since all of the Profile2 registration forms have the same id 'user_register_form' (even when using Profile2_RegPath module) how can I specify a Profile2 type when calling:

print(drupal_render(drupal_get_form('user_register_form')));


I need to be able to let the user create an account without having him leave the page. I'm able to print the Register and The Profile Fields to be edited, but they each have their own Action button which is what I do not want.
After looking through the Profile2 Git repository viewer for v1.3. I believe you want to do something like the following using profile2_attach_form. The `profile2_attach_form has the following API comment and function signature:

 /**
 * Attaches the profile forms of the profiles set in
 * $form_state['profiles'].
 *
 * Modules may alter the profile2 entity form regardless to which form it is
 * attached by making use of hook_form_profile2_form_alter().
 *
 * @param $form
 *   The form to which to attach the profile2 form. For each profile the form
 *   is added to @code $form['profile_' . $profile-&gt;type] @endcode. This helper
 *   also adds in a validation and a submit handler caring for the attached
 *   profile forms.
 *
 * @see hook_form_profile2_form_alter()
 * @see profile2_form_validate_handler()
 * @see profile2_form_submit_handler()
 */
function profile2_attach_form(&amp;$form, &amp;$form_state) { /* ... */ }


So, you could use it as follows by slightly modifying your code:

$user_register_form = drupal_get_form('user_register_form');
$form_state['profiles'] = array(
    'CUSTOM_PROFILE_TYPE_NAME' =&gt; profile2_get_types('CUSTOM_PROFILE_TYPE_NAME')
);
profile2_attach_form($user_register_form, $form_state);
print(drupal_render($user_register_form));


If you need to tweak any profile entity form displayed in some of your registration page(s), you may want to implement the specific FORM_ID version of hook_form alter, hook_form_profile2_form_alter().

EDIT 01/15/2015

minor API clarification and code cleanup from comments.