Printer

Printer is used to print only a certain JSF component, not the whole page. A printer is very flexible and can be attached to any command trigger like buttons and links.



Source

<h:form>
    <h:commandButton value="Print" type="button" icon="ui-icon-print">
        <p:printer target="image" />
    </h:commandButton>

    <p:graphicImage id="image" value="/images/nature1.jpg" />
</h:form>