我尝试通过我的模板中的meta标签禁止Internet Explorer。如何禁用Internet Explorer?
template.xhtml
:
<?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:ui="http://java.sun.com/jsf/facelets"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:f="http://java.sun.com/jsf/core">
<f:view locale="de_DE">
<h:head>
<f:facet name="first">
<h:outputText
value="<!--[if IE]>
<h1>No IE support.</h1>
<![endif]-->"
escape="false" />
</f:facet>
...
以这种方式,无法正常工作。我怎样才能实现它?
当你说“这行不通”时,当你试图在IE8中打开这个页面时会发生什么? – bouteillebleu
jsf呈现的页面显示。相反,我只想让文字“无IE支持”。 –
生成的HTML是否包含条件注释? –