我的代码工作正常,直到网站不是“https://”,但当网站转到“https:// ...”页面时,slidetoggle停止工作。我错过了什么?
标题中的代码:
$(document).ready(function(){
$(".flipChat").click(function(){
$(".cornerContactBox").slideToggle("slow");
});
});
我的内容代码:
<div class="livecontactCorner">
<div class="flipChat">Contact us</div>
<div class="cornerContactBox" style="display:none;">
All content goes here..................
</div><!--chatbox closing-->
</div><!--live chat corner closing-->
我的css是:
.livecontactCorner{
background:#CCC;
width:300px;
position:fixed;
right:10px;
bottom:0px;
font-size:13px;
text-align:justify;
}
.livecontactCorner, .flipChat{
border-top-left-radius:20px;
}
.cornerContactBox{
height:auto;
text-align:justify;
}
.flipChat{
width:270;
height:30px;
background:#0066CC;
cursor:pointer;
text-align:left;
font-family:arial,sans-serif;
font-weight:bold;
font-size:16px;
padding-top:10px;
padding-left:30px;
color:#0077ff;
color:white;
text-transform:uppercase;
}
我的工作链接(即不在https://中) Working Link
无效链接(即https://) Not working Link
高度重视任何帮助。 提前谢谢。
答案 0 :(得分:1)
请务必检查控制台是否有错误。目前jQuery被阻止,因为它使用http。所以你应该改变:
http://ajax.googleapis.com/ajax/libs/jquery/1.10.1/jquery.min.js
到
https://ajax.googleapis.com/ajax/libs/jquery/1.10.1/jquery.min.js
一切都应该没问题。