请输入搜索关键字!

苹果cmsV10播放器怎样设置成悬浮

发现源码网(www.crj100.com) | 2022-06-11 19:26 | 关注:98

摘要: 怎样把 苹果cms V10播放器设置成悬浮?在你的模板目录下template/模板名称/html/index的include.html里加入如下代码: style type = text/css . in { animation : ac 1 s ; } . out { position : fixed ; bottom : 50 % ;...

怎样把苹果cmsV10播放器设置成悬浮?在你的模板目录下template/模板名称/html/index的include.html里加入如下代码:

<style type="text/css">
 .in {
 animation: ac 1s;
}
.out {
 position: fixed; 
 bottom: 50%;(播放器位置)
 right: 1%;(播放器位置)
 z-index: 999;
 animation: an 0.5s;
}
</style>
<script>window.jQuery || document.write('<script src="/macplus/js/jquery-1.11.0.min.js"></script>')</script>
<script type="text/javascript">
 window.onload=function(){
 var ha = ($('.MacPlayer').find('table').offset().top + $('.MacPlayer').find('table').height());
 $(window).scroll(function(){ 
 if ( $(window).scrollTop() > ha ) { 
 $('.MacPlayer').find('table').removeClass('in').addClass('out');
 $('.MacPlayer').find('table').css('height','200px');(播放器大小)
 $('.MacPlayer').find('table').css('width','350px');(播放器大小)
 } else if ( $(window).scrollTop() < ha) { 
 $('.MacPlayer').find('table').removeClass('out').addClass('in'); 
 $('.MacPlayer').find('table').css('height','100%');
 } 
 });
}
</script>
有些模板可能没在include.html这个文件里需自行查找!悬浮播放器效果如图:

苹果cmsV10播放器怎样设置成悬浮

文章搜集于网络,如有侵权请联系本站,本文永久链接地址:http://www.crj100.com/yingshi/100.html
精品源码
视觉焦点

备案号:苏ICP备2021043059号