Configuring Registration and Login for Your Force Platform Site

,

An authenticated user is easier to track. By enabling your site for login and registration, you can capture data on prospective candidates, communicate with them, and allow them to update their own information. Having registered job applicants makes the application process easier. Force Platform Sites provides seamless integration with the Customer Portal product, as well as built-in login and registration logic, making it easy for public users become authenticated users.

This topic covers the following steps:

Configuring the Customer Portal

Force Platform Sites leverages a lot of existing Customer Portal settings. To integrate your site with a Customer Portal, you first need to enable the Customer Portal by doing the following:

1.
Click Setup Customize Customer Portal Settings.

2.
Click Edit.

3.
Select the Enable Customer Portal checkbox and click Save.

4.
Clone the Customer Portal User profile. Because the standard Customer Portal User profile is not editable, you need to create a clone so that you can give newly registered users access to the custom objects in the recruiting application. After login, users can view positions and other custom objects.

To clone the profile, do the following:

  1. Click Setup Manage Users Profiles.

  2. Click the Customer Portal User profile link.

  3. Click Clone.

  4. Name the profile “Custom: Customer Portal User” and click Save.

  5. Edit the profile you just created by clicking Edit on the User Profiles page.

  6. Under Custom Object Permissions, grant the profile Read access on all custom objects and Create access on Candidates.

5.
Now that the Customer Portal is enabled for registration and login, you must remove the PublicJobApplication and PublicJobApplicationConfirmation pages from the Enabled Visualforce Page Access list for your site. (You enable them for the Customer Portal user in the next step.) If you don’t, public site users will be able to see the application and confirmation pages without logging in!

Set the page access for your site by doing the following:

  1. Click Setup Develop Sites.

  2. Click the site label link for your site. This takes you to the Site Details page.

  3. Click Edit on the Site Pages related list.

  4. Remove the PublicJobApplication and PublicJobApplicationConfirmation pages from the Enabled Visualforce Pages list.

  5. Click Save.

6.
By disabling the PublicJobApplication and PublicJobApplicationConfirmation pages for your site and enabling them for the Custom:Customer Portal User profile, you allow only authenticated users to view these pages. By default, Customer Portal users can see all pages enabled for the associated public site, so you only have to enable these two pages for the profile.

Set the page access for profile by doing the following:

  1. Click Setup Manage Users Profiles.

  2. Click the Custom: Customer Portal User profile link.

  3. Scroll down to the Enabled Visualforce Page Access section and click Edit.

  4. Add the PublicJobApplication and PublicJobApplicationConfirmation pages to the Enabled Visualforce Pages list. This allows the default Customer Portal User to view these pages.

7.
Click Edit for the Customer Portal you just enabled.

8.
Configure the Customer Portal as follows:

  • Select the Login Enabled checkbox.

  • Select the Self-Registration Enabled checkbox.

  • Select a user for the Administrator field.

  • Optionally, set the Logout URL. If this isn’t set, users are taken to the site home page on logout.

  • Select Customer Portal User for the Default New User License.

  • Select the newly created Custom: Customer Portal User profile for the Default New User Profile.

  • Select User for the Default New User Role field.

9.
Click Save.

Your Self-Registration Settings section of the Customer Portal Setup page should look like this:

Figure 223. Customer Portal Self-Registration Settings


Associating the Customer Portal with Your Site

By associating your Force Platform site with a Customer Portal, you create a seamless bridge between your public website and the authenticated Customer Portal. Now that you have enabled and configured Customer Portal, you need to associate it with your site by doing the following:

1.
Click Setup Develop Sites.

2.
Click the site label link for your site. This takes you to the Site Details page.

3.
Click Login Settings.

4.
Click Edit.

5.
From the Enable Login For list, select the Customer Portal that you just configured.

6.
Select a Change Password Page. A default page is provided, but you can select your own page using the lookup field instead.

7.
Select the Require Non-Secure Connections (HTTP) checkbox if you want to override your organization’s security settings and exclusively use HTTP when logging in to the Customer Portal. If this checkbox is not selected, the Require Secure Connections (HTTPS) setting found at Setup Security Controls Session Settings is used to determine the security level.

8.
Click Save.

Browse to your site’s URL and notice that your site contains new login and registration links on the site header. The system automatically created the Visualforce pages and Apex classes necessary to integrate with the Customer Portal. The SiteHeader component automatically enabled the Login, Forgot Your Password?, and New User? links and associated them to the correct pages.

Figure 224. Job Posting Page with Registration and Login Links


Creating an Account and Updating the Apex Class with the Account ID

There are just a few more steps before your online recruiting flow is fully functional. Customer Portal users need to be associated with a contact under an account so that they can be tracked in the system. By creating an account that is associated with all of your job applicants, you can track applicant information as user records.

First, create a new Account, named Online Registration Account, and copy the 15-digit Account ID from the URL. The ID comes at the end of the URL. Update the SiteRegisterController with this ID. This ensures that all candidates registering through your public site are associated with the Online Registration Account.

Figure 225. Online Registration Account ID


To update the Account ID in the SiteRegisterController, do the following:

1.
Click Setup Develop Apex Classes.

2.
Click Edit next to SiteRegisterController.

3.
Find the private static Id PORTAL_ACCOUNT_ID = '<Account_ID>'; line and insert the ID for the Online Registration Account that you just created.

The line should look like this:

private static Id PORTAL_ACCOUNT_ID = '001D000000IVvTF';

4.
Click Save.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.15.3.136