[英]Show browser upgrade warning for IE8, IE7, IE6 in Wordpress
我正在開發Wordpress網站。 但是大多數功能未在IE8瀏覽器中顯示。 因此,我計划顯示瀏覽器升級警告,但不起作用。 誰能幫我。
<script>
var $buoop = {vs:{i:9,f:15,o:12.1,s:5.1},c:2};
function $buo_f(){
var e = document.createElement("script");
e.src = "//browser-update.org/update.js";
document.body.appendChild(e);
};
try {document.addEventListener("DOMContentLoaded", $buo_f,false)}
catch(e){window.attachEvent("onload", $buo_f)}
</script>
您可以使用IE條件注釋:
<!--[if lt IE 9]>
<script src="//browser-update.org/update.js"></script>
<![endif]-->
你可以試試這個
<!--[if IE 5]>
<script language="Javascript">
<!--
alert ("It looks like you aren't using Internet Explorer 7. To see our site correctly, please update.")
//-->
</script>
<![endif]-->
<!--[if IE 5.0]>
!--
alert ("It looks like you aren't using Internet Explorer 7. To see our site correctly, please update.")
//-->
</script>
<![endif]-->
<!--[if IE 5.5]>
!--
alert ("It looks like you aren't using Internet Explorer 7. To see our site correctly, please update.")
//-->
</script>
<![endif]-->
<!--[if IE 6]>
!--
alert ("It looks like you aren't using Internet Explorer 7. To see our site correctly, please update.")
//-->
</script>
<![endif]-->
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.