Skip to content

Instantly share code, notes, and snippets.

@markito
Created July 18, 2011 17:07
Show Gist options
  • Save markito/1090069 to your computer and use it in GitHub Desktop.
Save markito/1090069 to your computer and use it in GitHub Desktop.
JSF browser check
<c:when test="#{fn:containsIgnoreCase(request.getHeader('User-Agent'), 'MSIE 6') ||
fn:containsIgnoreCase(request.getHeader('User-Agent'), 'MSIE 7') ||
fn:containsIgnoreCase(request.getHeader('User-Agent'), 'MSIE 8') ||
fn:containsIgnoreCase(request.getHeader('User-Agent'), 'Firefox/3.2')}">
<h:panelGrid columns="1" id="browserCheck">
<h2>#{bundle.BrowserNotSupported} <br /></h2>
<strong>Browser Information: </strong>#{request.getHeader('User-Agent')}
<h:graphicImage library="img" name="img/JavaTopiary.png" />
</h:panelGrid>
</c:when>
<c:otherwise>
....
</c:when>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment