title: How to trigger an event in the parent page from the included page in PrimeFaces?
body: <p>I have the <code>parent.xhtml</code> page in which I've included a <code>child.xhtml</code> page.
  In the child page I have a button and upon clicking it I want to trigger a listener/action event in the parent page (let's say I want to execute a method from the parent's bean).</p>
  
  <p><strong>Edit</strong>: I need to make the child page as atomic as possible so it can be reused in other parents/wrappers too. That would mean to simply make it broadcast an event which can be listened by whoever will be the parent page.</p>
  
  <p>parent.xhtml:</p>
  
  <pre><code>&lt;ui:include src="/content/childPage.xhtml"&gt;&lt;/ui:include&gt;
  </code></pre>
  
  <p>child.xhtml</p>
  
  <pre><code>&lt;p:commandButton doSomething....&gt;
  &lt;/p:commandButton&gt;
  </code></pre>
  
  <p>I'm using PrimeFaces 6, JSF 2.</p>