title: oncomplete="PF('dlg').hide();" causes "PF cannot be found" error
body: <p>On the PrimeFaces website, they have many examples of how to use their components. One feature that I find very useful is the ability to show and hide PrimeFaces dialogs. In the examples this is accomplished like this:</p>
  
  <pre><code>&lt;p:dialog header="Enter FirstName" widgetVar="dlg" resizable="false"&gt;  
      &lt;h:form id="form"&gt;  
  
          &lt;h:panelGrid columns="2" style="margin-bottom:10px"&gt;  
              &lt;h:outputLabel for="firstname" value="Firstname:" /&gt;  
              &lt;p:inputText id="firstname" value="#{pprBean.firstname}" /&gt;  
          &lt;/h:panelGrid&gt;  
  
          &lt;p:commandButton id="submitButton" value="Submit" update=":display" oncomplete="PF('dlg').hide();"/&gt;  
  
      &lt;/h:form&gt;  
  &lt;/p:dialog&gt;  
  
  &lt;p:outputPanel id="display" style="display:block;margin-top:10px;"&gt;  
      &lt;h:outputText id="name" value="Hello #{pprBean.firstname}" rendered="#{not empty pprBean.firstname}"/&gt;  
  &lt;/p:outputPanel&gt;  
  </code></pre>
  
  <p>If you notice in the command button, it calls:</p>
  
  <pre><code>oncomplete="PF('dlg').hide();"
  </code></pre>
  
  <p>However, when I try to reproduce this example, my Firebug debugger complains that <code>PF</code> cannot be found. Is there something that I need to add to my JSF page to have access to <code>PF</code>?</p>