Converting anchors to action in topbar-menu
Posted: 05 Oct 2016, 05:14
Hello,
I'm trying to replace the anchor(s) in topbar-menu (within topbar.xhtml) so that I can link an action on click.
I though of using p:commandLink but I find I have to override the color style in line otherwise the link comes out blue (I use the apollo-blue theme)
For example, I'm trying to replace something like the following that comes out as off-white:
<a href="#"><span class="topbar-item-text">Settings</span><span class="topbar-icon fa fa-gear"></span></a>
By:
<p:commandLink action="#{logoutBean.logout}" style="color : #d8d8d8;">
<a href="#"><span class="topbar-item-text">Logout</span><span class="topbar-icon fa fa-sign-out"></span></a>
</p:commandLink>
If I don't put the style="color : #d8d8d8;" the link comes out blue (apollo blue)
Is there another way of achieving what I want to do without overriding the color ?
Thanks.
JB
I'm trying to replace the anchor(s) in topbar-menu (within topbar.xhtml) so that I can link an action on click.
I though of using p:commandLink but I find I have to override the color style in line otherwise the link comes out blue (I use the apollo-blue theme)
For example, I'm trying to replace something like the following that comes out as off-white:
<a href="#"><span class="topbar-item-text">Settings</span><span class="topbar-icon fa fa-gear"></span></a>
By:
<p:commandLink action="#{logoutBean.logout}" style="color : #d8d8d8;">
<a href="#"><span class="topbar-item-text">Logout</span><span class="topbar-icon fa fa-sign-out"></span></a>
</p:commandLink>
If I don't put the style="color : #d8d8d8;" the link comes out blue (apollo blue)
Is there another way of achieving what I want to do without overriding the color ?
Thanks.
JB