function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
MoDiggityMoDiggity 

Passing URL parameters through Communities login process?

So if a user accesses a page in the community that requires authentication, how do I hold onto that URL throughout the login process or the self-registration process so that we can go back to it after logging in?
NagaNaga (Salesforce Developers) 
Hi Modiggity,

To direct your users to a specific community after authenticating, you need to specify a URL with the community request parameter. If you don’t add the parameter, the user is sent to either /home/home.jsp (for a portal or standard application) or to the default sites page (for a site) after authentication completes.

Example

For example, with a Single Sign-On Initialization URL, the user is sent to this location after being logged in. For an Existing User Linking URL, the “Continue to Salesforce” link on the confirmation page leads to this page.The following is an example of a community parameter added to the Single Sign-On Initialization URL, where:orgID is your Auth. Provider ID
URLsuffix is the value you specified when you defined the authentication provider
https://login.salesforce.com/services/auth/sso/orgID/URLsuffix?community=https://acme.force.com/support

Please let me know if this helps

Best Regards
Naga Kiran