Record and field access

A common source of confusion for a Visualforce developer is configuring a Force.com site to allow unauthenticated access to Salesforce records and specific fields. This is usually configured via the Profiles menu located at Your Name | Setup | Administration Setup | Profiles. However, access to records and fields for a Force.com site is configured via the setup page for the site in question.

In this recipe, we will configure the Force.com site created in the first recipe to allow public access to contact records. We will then create a Visualforce page that allows a visitor to enter an e-mail address into a form on the Force.com site and extract the contact record matching the e-mail address, displaying the First Name,

Get Visualforce Development Cookbook - Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.