Before the upgrade to Primefaces 3.2 we were able to fix the issue using some JQuery, however it no longer works:
Code: Select all
function setMenuButtonClickEvent() {
if (jQuery.browser.msie) {
jQuery("#logoutForm\\:welcomeMenuButton_button").bind('click',
function() {
var currentVal = jQuery("#logoutForm\\:welcomeMenuButton_menu").css("display");
if (currentVal == "block") {
jQuery("#logoutForm\\:welcomeMenuButton_menu").css("display", "none");
} else {
jQuery("#logoutForm\\:welcomeMenuButton_menu").css("display", "block");
}
});
}
}
Before the upgrade to Primefaces 3.2 we were able to fix the issue using some JQuery:Before the upgrade to Primefaces 3.2 we were able to fix the issue using some JQuery:
Ideally we'd like to be able to use the component as shown out of the box. Given that it works in IE in the showcase there must be something we're doing in our code that causes it to fail. Our .xhtml file is as follows:
Code: Select all
<?xml version='1.0' encoding='UTF-8' ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:p="http://primefaces.org/ui"
xmlns:f="http://java.sun.com/jsf/core"
xmlns:ui="http://java.sun.com/jsf/facelets">
<f:view>
<ui:composition id="headerPanel">
<p:graphicImage id="workspaceHeaderImage" style="margin: 4px 4px 4px 10px;" value="#{resource['images/efmLogo.png']}" />
<h4 id="workspaceHeaderText" class="page-header-text">
<h:form id="logoutForm" >
<p:menuButton id="welcomeMenuButton" value="#{msg['ws-page.welcome']} #{userSessionBean.loggedInUser.firstName} #{userSessionBean.loggedInUser.lastName} !" rendered="#{view.viewId == '/ws.xhtml'}">
<p:menuitem value="#{msg['ws-page.signout']}" actionListener="#{loginBean.logout}" style="display: inline-block !important;"/>
</p:menuButton>
</h:form>
</h4>
</ui:composition>
</f:view>
</html>
We have a fairly straightforward implementation but it doesn't want to work in IE for some reason....
PrimeFaces 3.2 Final, Java EE 6, NetBeans 7.0.1, Mojarra 2.1.6 (JSF 2.1), Apache Tomcat - 7.0.20