<p:commandButton> con imagenes

<h:commandButton title="Hola" image="/resources/images/boton/16x16/list.png"/>

AGREGANDOLOS AL CSS

http://stackoverflow.com/questions/16614443/pcommandbutton-with-icon-image-not-showing

.ui-icon-excel {
            background: url("images/toexcel.gif")  no-repeat top left !important;;
     }

Then use your command button as shown below,

<p:commandButton type="submit"
             id="cr1001_command_toexcel"
             image="ui-icon-excel"
             action="#{pc_Cr1001.doCr1001_command_toexcelAction}" ajax="false">
              </p:commandButton>


<h:commandButton image="images/toexcel.gif"/>

Last updated