简单展开(JQuery)不适用于InternetExplorer11,但适用于其他浏览器
Simple-Expand (JQuery) not working in Internet Explorer 11 but works in other browsers
我在Windows盒子上运行XAMPP。下面是我的测试文件:
<html>
<head>
<title>very nice file</title>
</head>
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<body>
<a class="expander" href="#">click me</a>
<div class="content">
I WANT TO HIDE THISSSS.
</div>
</body>
</html>
<script src="http://code.jquery.com/jquery-latest.js"></script>
<script src="https://raw.githubusercontent.com/redhotsly/simple-expand/master/src/simple-expand.js"></script>
<script type="text/javascript" language="javascript">
$(document).ready(function() {
$('.expander').simpleexpand();
});
</script>
当我在Internet Explorer中浏览该文件时,我会看到"点击我"answers"我想隐藏THISSSS"。当我在其他浏览器中浏览时,我会看到"点击我",点击它会取消隐藏"我想隐藏THISSSS"文本。
搜索了一整夜,仍然一无所获!有什么想法吗?谢谢
你真的需要那个扩展器吗?如果你只是想隐藏/显示一个内容。您可以用几行代码创建一个,因为您使用的是jquery
你可以在这里试试这个简单的小提琴https://jsfiddle.net/yzdthzhL/
你可以播放你想要的代码。
顺便说一句。我不确定这是否有帮助,但是。将脚本添加到html文档中会很好。
<html>
<head>
<script src="somelibrarieshere"></script>
</head>
<body>
<script src="somelibrarieshere"></script>
</body>
</html>
并且不在html块之外。这样更好。:)祝你度过美好的一天,伙计。
相关文章:
- JQueryhide()不适用于Mozzilla,但适用于Chrome
- PHP中的setcookie仅适用于localhost
- html5 drawImage适用于firefox,而不是chrome
- 提供“;onClick"适用于iPad(触摸屏)和桌面用户的默认功能
- jQuery表单验证适用于Mozilla和Internet Explorer,但不适用于Chrome或Safari
- ResolveUrl是否适用于././也
- Firebase updateChildValues适用于IOS,但不适用于Web和Android
- JavaScript警报适用于int,但不适用于string
- SQLite插件适用于Mac和Windows,但不适用于手机上的Safari
- Regex Replace仅适用于Last Match
- window.onload适用于aspx页面,但不适用于普通html
- Jquery Ajax POST不工作.适用于GET
- 画布上的自定义字体仅适用于safari
- Javascript仅适用于alert()和Debug模式
- JS适用于Firefox和Safari,但不适用于Chrome.此处'是我的网站
- Regex不适用于Firefox,但适用于Chrome
- 通过单击主菜单外部关闭子菜单'不适用于IE,但适用于Firefox&铬
- AngularJS$http.post没有'不适用于Chrome,仅适用于IE
- Javascript仅适用于jQuery mobile中的页面刷新
- 关闭当前选项卡并打开一个新的-仅适用于Chrome