Thursday, 29 October 2015

Displaying a Popup on Page Load


This blog we will see how to display a popup on page load.
The below steps we need to follow to display a popup on page load.
1. Create a page which one you want to display on Page.
2. Create a popup which one you want to display after the page load.


<af:popup childCreation="deferred" autoCancel="disabled" id="p1">
      <af:dialog title="Displaying the Popup on Page Load" id="d2">
            <f:facet name="buttonBar"/>
            <af:panelFormLayout id="pfl1">
            <af:outputText value="This is the onload popup." id="ot2"/>
            </af:panelFormLayout>
      </af:dialog>
</af:popup>

3. Add the af:showPopupBehaviorafter the af:form like the below
4. Now set the trigger type to load in af:showPopupBehavior.
 Now run your page and the popup will comes up after page load like the below.
You Can download the code: Download

Thanks..

3 comments:

  1. Impressed alot.I really like your blog.Thanks for the post. Pop up System Services in Malaysia

    ReplyDelete
  2. The blog was absolutely fantastic! Lot of information is helpful in some or the other way. Keep updating the blog, looking forward for more content...Great job, keep it up.
    Pop Up System services in Malaysia

    ReplyDelete