作者 景龙
1 个管道 的构建 通过 耗费 0 秒
... ... @@ -50,7 +50,8 @@
<ul class="swiper-wrapper">
<volist name="res['m_image_url']" id="vo">
<li class="swiper-slide">
<img src="{:cmf_get_image_url($vo.url)}" alt="" />
<img src="__TMPL__/public/assets/images/cicon_43@2x.png" alt="">
<!-- <img src="{:cmf_get_image_url($vo.url)}" alt="" /> -->
<div class="index_fourth_top index_shans">
<div class="index_fourth_top_img">
<img src="__TMPL__/public/assets/images/cicon_102@2x.png" alt="" />
... ...
... ... @@ -15,7 +15,21 @@
position: absolute;
top: 0;
width: 100%;
height: 97%;
height: 100%;
}
.video_bg video {
width: 100%;
height: 100%;
}
.fourth_video {
height: 3.6rem;
}
.video_bg {
height: 3.5rem;
background-color: black;
}
</style>
</head>
... ... @@ -54,7 +68,7 @@
</ul>
<input type="hidden" value="0" name="city_id" id="city_id">
<div style="display:none;">
<input type="submit" id="city_submit"/>
<input type="submit" id="city_submit" />
</div>
</form>
</div>
... ... @@ -119,23 +133,23 @@
});
//登录
var users = $('#users').val();
if(users == 0) {
if (users == 0) {
//监听播放时间
video_mask('您还不是会员,可试看20秒');
var video = document.getElementById('video');
//使用事件监听方式捕捉事件
video.addEventListener("timeupdate", function () {
video.addEventListener("timeupdate", function() {
var timeDisplay;
//用秒数来显示当前播放进度
timeDisplay = Math.floor(video.currentTime);
console.log(Math.floor(video.currentTime));
video.addEventListener('play', function () {
video.addEventListener('play', function() {
video.currentTime = 0;
});
//当视频播放到 15s的时候做处理
if (timeDisplay >= 20) {
video.addEventListener('play', function () {
video.addEventListener('play', function() {
video.currentTime = 0;
}),
video_mask('会员可观看完整视频');
... ... @@ -148,9 +162,10 @@
function bofang() {
video.play();
$('#video').show();
$('.video_poster').hide();
$("#video").attr("controls", "controls");
$(".fourth_video_start").hide();
$('.video_poster').css('z-index', '-1');
}
// swiper
... ... @@ -183,21 +198,21 @@
$('.curren').children('li').find('.txt-cut').css('color', 'rgba(153, 153, 153, 1)');
switch_video(index);
});
// $(".select ul li").click(function() {
// $(".select input").val($(this).text());
// $(".select ul").hide();
// var index = $(this).index();
// $(".curren")
// .eq(index)
// .addClass("video_active")
// .siblings()
// .removeClass("video_active");
// });
// $(".select ul li").click(function() {
// $(".select input").val($(this).text());
// $(".select ul").hide();
// var index = $(this).index();
// $(".curren")
// .eq(index)
// .addClass("video_active")
// .siblings()
// .removeClass("video_active");
// });
var value = $('#cityName').val();
if(value != ''){
if (value != '') {
$('.show_city').val(value);
}else{
} else {
$('.show_city').val('所有');
}
... ... @@ -206,9 +221,14 @@
var city_id = $(this).val();
$('#city_id').val(city_id);
$('form').submit();
window.location.href = '/portal/region/getMoreVideo?city_id='+city_id;
window.location.href = '/portal/region/getMoreVideo?city_id=' + city_id;
});
$('.star_gall_img li').each(function() {
$(this).click(function() {
$('#video').css('display', 'none');
$('.video_poster').css('visibility', 'visible!important');
});
});
//切换视频
function switch_video(index) {
//视频路径
... ... @@ -222,14 +242,20 @@
$('#video').attr('src', oneVideo);
// 视频封面图
var oneCover = li_index.find('.li_img').attr('src');
$('.video_poster').attr('src', oneCover);
// $('.video_poster').css('z-index', '10');
var img = li_index.find('.li_img').attr('src');
$('.video_poster').attr('src', img);
$('.fourth_video_start').css({
'z-index': "100",
"display": "block"
});
$('#video').css('z-index', '0');
$('.video_poster').show();
$(".fourth_video_start").show();
// var oneCover = li_index.find('.li_img').attr('src');
// $('.video_poster').attr('src', oneCover);
// $('.fourth_video_start').css({
// 'z-index': "100",
// "display": "block"
// });
//标题,国家,取景,上映时间
var post_title = li_index.children('.li_post_title').val();
... ...
... ... @@ -5,17 +5,28 @@ $(function() {
$('.nav_down').hide();
$('.navImg1 img').attr('src', host + "/images/cicon_02@2x.png")
});
//导航
$('.navImg1 img').click(function() {
$('.navImg1 img').click(function(e) {
if ($(this).attr('src') == host + "/images/cicon_02@2x.png") {
e.stopPropagation();
$(this).attr('src', host + '/images/xx.png');
$('.nav_down').slideDown();
} else {
console.log(1)
$(this).attr('src', host + '/images/cicon_02@2x.png');
$('.nav_down').slideUp();
}
});
// 关闭导航
$(document).click(function(e) {
if (!$(e.target).closest(".nav_down").length) {
$(".nav_down").slideUp(200);
$('.navImg1 img').attr('src', host + "/images/cicon_02@2x.png")
// $(this).children('.bottom_liCir p').css('color', '#999999');
}
});
//二级导航
$('.nav_downN').each(function() {
$(this).click(function() {
... ...
... ... @@ -18,7 +18,7 @@
<img src="__TMPL__/public/assets/images/cicon_03@2x.png" alt="" />
</div>
<!--导航下拉-->
<div class="nav_down">
<div class="nav_down" id="over">
<!--未登录-->
<notempty name="user">
<!--登陆后-->
... ...