You need to sign in to do that
Don't have an account?
krishnag
how to update a standard object record using sites
hi i created a site where the guest users can edit their personal information. the operation should be on lead object.so i created a custom controller submitt which will save the edited info by user. it worked fine in the develoepr mode. when i put that page in sites its not updating the information on the lead record. when i went to public access settings and checked there are no modify permission for leads on sites. how can i achieve this task through sites.
sites only grants read and create on standard objects. You will need to authenticate your site visitors with a valid portal license in order to gain update/delete access on standard objects.
u mean we need to have a customer portal setup.but in my case the user is guestuser he is not contact
yes as a guest user (site user) you can only create or read standard objects. In order to gain update/delete access you need to authenticate users via portal (with the proper licenses).
so there is no option for a guest user to edit his info.,beacuse as you said the authentication can be done only thru portal licenses the user can be a portal user only if he is a contact atleast ,as a lead he has no autorization right?
if you use custom objects rather than leads you can but lead is a standard object and site license doesn't provide update on leads.
hi i used a custom object to store the updated data instead of saving in standard object.even then iam not able to store the data in custom object using sites.
this example might help:
Book: Force Platform Developer Guide Chapter 14 shows how to expose an application on Force.com Sites
You can update leads writing a custom controller. And campaign members as well. For example lead could this way post reply to event invitation.
What I found is that a VF controller without sharing can update any record. But if you put the record directly on the page and it has an "ID", the fields won't be writable.
So if you want to do an update, there's two work arounds--
See this thread for details -- http://boards.developerforce.com/t5/Force-com-Sites-Site-com/Site-written-in-VF-and-access-to-standard-objects-with-Public/td-p/700949
Ken's link above is broken, but here's the updated link to the article: https://developer.salesforce.com/forums/?id=906F00000009B3YIAU