简体   繁体   中英

How to remove the border in p:commendlink?

I have ap:commandLink in xhtml page

<p:commandLink onclick="routeDeleteConfirmation.show()" title="Delete">
                    <h:graphicImage class="deleteBinButtonLnk" />
                    <f:setPropertyActionListener value="#{route}" 
                    target="#{routeController.selectedRouteHeader}"/>
</p:commandLink>

Css:

.deleteBinButtonLnk {  width: 17px; height: 19px;
                       border-style: none !important;
                       padding: 2px 2px;
                       background: url('../images/buttons/delete_bin_off.png')
                       no-repeat;
}

.deleteBinButtonLnk:hover{ width: 17px; height: 19px;
                           border: none;
                           background: url('../images/buttons/delete_bin_on.png')
                           no-repeat;

here it displaying border for the images in h:graphicImage. i don't need border for it.

please tell a solution.

I Got it.

styleClass instead of <h:graphicImage>

<p:commandLink 
   styleClass="accountEditBtn"
   update="@form"
   actionListener="#{someBean.someListener}"
</p:commandLink>

Css class

.accountEditBtn { background-image: url('../resources/image/pencil_black.png'); }

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM