我有这个横幅图像旋转器使用javascript在wp 4.1更新后停止工作。
<script type="text/javascript">
var imgs2 = new Array("http://www.chinasurfreport.com/wp-content/uploads/2014/09/LRG-BANNER.jpg","http://www.chinasurfreport.com/wp-content/uploads/2014/10/thehundreds2.jpg");
var lnks2 = new Array("http://www.bluehawaiisurf.com.cn/","http://www.bluehawaiisurf.com.cn/");
var alt2 = new Array("lrg-banner","the-hundreds-banner");
var currentAd2 = 0;
var imgCt2 = 2;
function cycle2() {
if (currentAd2 == imgCt2) {
currentAd2 = 0;
}
var banner2 = document.getElementById('adBanner2');
var link2 = document.getElementById('adLink2');
banner2.src=imgs2[currentAd2]
banner2.alt=alt2[currentAd2]
document.getElementById('adLink2').href=lnks2[currentAd2]
currentAd2++;
}
window.setInterval("cycle2()",20000);
</script>
<a href="http://www.bluehawaiisurf.com.cn/" id="adLink2" target="_blank">
<img src="http://www.chinasurfreport.com/wp-content/uploads/2014/09/LRG-BANNER.jpg" id="adBanner2" border="0" width="325" height="724"></a>
当我在chrome中“检查元素”时,它说
script {
display: none;
}
我无法改变这一点。我期待一场冲突?
答案 0 :(得分:0)
haha bloody安装了新的镀铬扩展程序adblock plus,将其删除。 DOH!