I am using a method is page's "action" attribute. When I am testing this by login into salesforce, it's working fine. But when I used this page on Force.com sites, the action method didn't execute every-time. Sometime it works and some time don't work.
Can anyone suggest why it's behaving like this ?
VF Page:
<apex:page sidebar="false" showHeader="false" standardStylesheets="false" applyHTMLTag="false" applyBodyTag="false" controller="APTS_eCommerceController" action="{!setPrereqs}" >
</apex>
Controller :
public void setPrereqs(){
CustomObject obj = new CustomObject();
insert obj;
}
Attribution to: S.Sharma
This content is remixed from stackoverflow or stackexchange. Please visit https://salesforce.stackexchange.com/questions/34953