You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
340 lines
13 KiB
HTML
340 lines
13 KiB
HTML
5 years ago
|
<extend name="Public/bases" />
|
||
|
<block name="css">
|
||
|
<link href="__CSS__/swiper.min.css" rel="stylesheet" >
|
||
|
<link href="__CSS__/{:C('DEFAULT_THEME')}/index.css" rel="stylesheet" >
|
||
|
</block>
|
||
|
<block name="header">
|
||
|
<div class="header">
|
||
|
<section class="wrap">
|
||
|
<notempty name='sitebase[sites_wap_logo]' >
|
||
|
<a class="hbtn left logo"><span class="table"><span class="table-cell"><img src="{:get_cover($sitebase['sites_wap_logo'],'path')}"></span></span></a>
|
||
|
<else />
|
||
|
<a class="hbtn left logo"><span class="table"><span class="table-cell"><img src="{:get_cover(C('WAP_SET_LOGO'),'path')}"></span></span></a>
|
||
|
</notempty>
|
||
|
<div class="caption"><span class="table"><span class="table-cell">首页</span></span></div>
|
||
|
</section>
|
||
|
</div>
|
||
|
<div class="header-space"></div>
|
||
|
</block>
|
||
|
<block name="body">
|
||
|
|
||
|
|
||
|
<div class="trunk-box">
|
||
|
<!-- 轮播图 -->
|
||
|
<div class="banner">
|
||
|
<div <if condition="count($slider) gt 1">id="banner-carousel"</if> class="swiper-container">
|
||
|
<div class="swiper-wrapper">
|
||
|
<notempty name="slider">
|
||
|
<volist name="slider" id="vo">
|
||
|
<div class="swiper-slide">
|
||
|
<a class="pic" target="{$vo['target']}" href="<notempty name='vo.url'>{$vo.url}<else />javascript:;</notempty>"><span class="font table"><span class="table-cell">{$vo['title']}</span></span><if condition="@fopen($vo['data'],'r')"><img src="{$vo['data']}" /><else/></if></a>
|
||
|
</div>
|
||
|
</volist>
|
||
|
<else />
|
||
|
<div class="swiper-slide">
|
||
|
<a class="pic" href="javascript:;"><span class="font table"><span class="table-cell">----游戏</span></span></a>
|
||
|
</div>
|
||
|
</notempty>
|
||
|
</div>
|
||
|
<!-- 如果需要分页器 -->
|
||
|
<div class="swiper-pagination"></div>
|
||
|
</div>
|
||
|
</div>
|
||
|
|
||
|
<div class="wrap">
|
||
|
|
||
|
<div class="contact">
|
||
|
<div class="contact-box clearfix">
|
||
|
<a href="javascript:;" data-value="<notempty name='sitebase.site_qq'>{$sitebase.site_qq}<else />{:C('PC_SET_SERVER_QQ')}</notempty>" class="item contact-item jschatqq"><img src="__IMG__/wap/home_btn_qq.png" class="img"><span>客服QQ</span></a>
|
||
|
<a href="javascript:;" data-value="{$sitebase.site_qq_qun}" data-url="{$sitebase.site_qq_qunurl}" class="item contact-item jschatqqqun"><img src="__IMG__/wap/home_btn_qqgroup.png" class="img"><span>玩家QQ群</span></a>
|
||
|
<a href="tel:<notempty name='sitebase.site_tel'>{$sitebase.site_tel}<else />{:C('PC_SET_SERVER_TEL')}</notempty>" class="item contact-item"><img src="__IMG__/wap/home_btn_tel.png" class="img"><span>联系电话</span></a>
|
||
|
<a href="{:U('Down/index',array('account'=>I('account')))}" class="item contact-item"><img src="__IMG__/wap/home_btn_download.png" class="img"><span>APP下载</span></a>
|
||
|
</div>
|
||
|
</div>
|
||
|
|
||
|
<div class="recommend">
|
||
|
<div class="list-title"><a href="{:U('Game/index',array('rs'=>1,'account'=>I('account')))}" class="list-more">更多<img src="__IMG__/wap/home_btn_more.png"></a><i></i><span>精品推荐</span></div>
|
||
|
<ul class="clearfix">
|
||
|
<notempty name="recgame">
|
||
|
<volist name="recgame" id="vo">
|
||
|
<li>
|
||
|
<div class="item">
|
||
|
<a href="{:U('Game/detail',array('name'=>$vo['game_name'],'source'=>$vo['game_source'],'account'=>I('account')))}" class="name"><div class="pic"><span class="font table"><span class="table-cell">----游戏</span></span><img src="{:get_cover($vo['game_icon'],'path')}"></div></a>
|
||
|
<div class="but">
|
||
|
<span class="table">
|
||
|
<span class="table-cell">
|
||
|
<eq name="vo.game_source" value="2">
|
||
|
<a href="javascript:;" date-id="{$vo[id]}" date-value="{$vo.game_dow_url}" date-promote="{$vo.promote_id}" class="butn goto <empty name='vo.game_dow_url'>disabled</empty>">下载</a>
|
||
|
<else />
|
||
|
<a href="http://{$_SERVER['HTTP_HOST']}{:U('Down/down_file',array('game_id'=>$vo['game_id'],'promote_id'=>$vo['promote_id'],'type'=>$vo['sdk_version']))}" class="butn">下载</a>
|
||
|
</eq>
|
||
|
</span>
|
||
|
</span>
|
||
|
</div>
|
||
|
<div class="txt">
|
||
|
<a href="{:U('Game/detail',array('name'=>$vo['game_name'],'source'=>$vo['game_source'],'account'=>I('account')))}" class="name">{:str_replace(array('(安卓版)','(苹果版)'),'',$vo['game_name'])}</a>
|
||
|
<p class="info"><span>{:set_number_short($vo['download_number'])}人下载</span><i></i><span>{$vo.game_size}MB</span></p>
|
||
|
<p class="description">{$vo.summary}</p>
|
||
|
</div>
|
||
|
</div>
|
||
|
</li>
|
||
|
</volist>
|
||
|
<else />
|
||
|
<div class="empty">
|
||
|
<span class="table">
|
||
|
<span class="table-cell">
|
||
|
<img src="__IMG__/wap/empty_icon_list.png" class="empty-icon">
|
||
|
<p class="empty-text"><span>无数据</span></p>
|
||
|
</span>
|
||
|
</span>
|
||
|
</div>
|
||
|
</notempty>
|
||
|
</ul>
|
||
|
</div>
|
||
|
<div class="pic-text clearfix">
|
||
|
<div class="newsgame recommend">
|
||
|
<div class="list-title"><a href="{:U('Game/index',array('rs'=>3,'account'=>I('account')))}" class="list-more">更多<img src="__IMG__/wap/home_btn_more.png"></a><i></i><span>最新上线</span></div>
|
||
|
<ul class="clearfix">
|
||
|
<notempty name="newsgame">
|
||
|
<volist name="newsgame" id="vo">
|
||
|
<li>
|
||
|
<div class="item">
|
||
|
<a href="{:U('Game/detail',array('name'=>$vo['game_name'],'source'=>$vo['game_source'],'account'=>I('account')))}" class="name">
|
||
|
<div class="pic"><span class="font table"><span class="table-cell">----游戏</span></span><img src="{:get_cover($vo['game_icon'],'path')}"></div>
|
||
|
</a>
|
||
|
<div class="but">
|
||
|
<span class="table">
|
||
|
<span class="table-cell">
|
||
|
<eq name="vo.game_source" value="2">
|
||
|
<a href="javascript:;" date-id="{$vo[id]}" date-value="{$vo.game_dow_url}" date-promote="{$vo.promote_id}" class="butn goto <empty name='vo.game_dow_url'>disabled</empty>">下载</a>
|
||
|
<else />
|
||
|
<a href="http://{$_SERVER['HTTP_HOST']}{:U('Down/down_file',array('game_id'=>$vo['game_id'],'promote_id'=>$vo['promote_id'],'type'=>$vo['sdk_version']))}" class="butn">下载</a>
|
||
|
</eq>
|
||
|
</span>
|
||
|
</span>
|
||
|
</div>
|
||
|
<div class="txt">
|
||
|
<a href="{:U('Game/detail',array('name'=>$vo['game_name'],'source'=>$vo['game_source'],'account'=>I('account')))}" class="name">{:str_replace(array('(安卓版)','(苹果版)'),'',$vo['game_name'])}</a>
|
||
|
<p class="info"><span>{:set_number_short($vo['download_number'])}人下载<span><i></i><span>{$vo.game_size}MB</span></p>
|
||
|
<p class="description">{$vo.summary}</p>
|
||
|
</div>
|
||
|
</div>
|
||
|
</li>
|
||
|
</volist>
|
||
|
<else />
|
||
|
<div class="empty">
|
||
|
<span class="table">
|
||
|
<span class="table-cell">
|
||
|
<img src="__IMG__/wap/empty_icon_list.png" class="empty-icon">
|
||
|
<p class="empty-text"><span>无数据</span></p>
|
||
|
</span>
|
||
|
</span>
|
||
|
</div>
|
||
|
</notempty>
|
||
|
</ul>
|
||
|
</div>
|
||
|
|
||
|
</div>
|
||
|
<div class="hotgift recommend">
|
||
|
<div class="list-title"><a href="{:U('Gift/index',array('rs'=>2,'account'=>I('account')))}" class="list-more">更多<img src="__IMG__/wap/home_btn_more.png"></a><i></i><span>热门礼包</span></div>
|
||
|
<ul class="clearfix">
|
||
|
<notempty name="hotgift">
|
||
|
<volist name="hotgift" id="vo">
|
||
|
<li>
|
||
|
<div class="item clearfix">
|
||
|
<a href="{:U('Gift/detail',array('id'=>$vo['id'],'account'=>I('account')))}" class="name">
|
||
|
<div class="pic">
|
||
|
<span class="font table"><span class="table-cell">----游戏</span></span>
|
||
|
<img src="{:get_cover($vo['game_icon'],'path')}" class="icon">
|
||
|
</div>
|
||
|
</a>
|
||
|
<div class="but">
|
||
|
<span class="table">
|
||
|
<span class="table-cell">
|
||
|
<gt name='vo.recordid' value='0'>
|
||
|
<a href="javascript:;" class="butn jsgetgift disabled">已领取</a>
|
||
|
<else />
|
||
|
<a href="javascript:;" data-id="{$vo.id}" class="butn jsgetgift">领取</a>
|
||
|
</gt>
|
||
|
</span>
|
||
|
</span>
|
||
|
</div>
|
||
|
<div class="txt">
|
||
|
<a href="{:U('Gift/detail',array('id'=>$vo['id'],'account'=>I('account')))}" class="name">{:str_replace(array('(安卓版)','(苹果版)'),'',$vo['game_name'])}</a>
|
||
|
<p class="surplus"><span>剩余:<em><notempty name="vo.novice">{:count(explode(',',$vo['novice']))}<else />0</notempty></em></span><i></i><span>{$vo.server_name}</span></p>
|
||
|
<p class="time">有效期:{$vo.start_time|date='y.m.d',###}-{$vo.end_time|date='y.m.d',###}</p>
|
||
|
</div>
|
||
|
</div>
|
||
|
</li>
|
||
|
</volist>
|
||
|
<else />
|
||
|
<div class="empty">
|
||
|
<span class="table">
|
||
|
<span class="table-cell">
|
||
|
<img src="__IMG__/wap/empty_icon_list.png" class="empty-icon">
|
||
|
<p class="empty-text"><span>无数据</span></p>
|
||
|
</span>
|
||
|
</span>
|
||
|
</div>
|
||
|
</notempty>
|
||
|
</ul>
|
||
|
</div>
|
||
|
</div>
|
||
|
</div>
|
||
|
|
||
|
|
||
|
</block>
|
||
|
|
||
|
<block name="footer">
|
||
|
<include file="Public:footer" />
|
||
|
</block>
|
||
|
|
||
|
<block name="script">
|
||
|
<script src="__JS__/swiper.min.js"></script>
|
||
|
<script src="__STATIC__/layer/layer.js"></script>
|
||
|
<script src="__JS__/clipboard.min.js"></script>
|
||
|
<script>
|
||
|
function Copy(str,that,index){
|
||
|
text = str;
|
||
|
var clipboard = new Clipboard('.copy',{
|
||
|
text: function() {
|
||
|
return text;
|
||
|
}
|
||
|
});
|
||
|
clipboard.on('success', function(e) {
|
||
|
that.text('复制成功');
|
||
|
e.clearSelection();
|
||
|
setTimeout(function(){layer.close(index);layer.msg('复制成功');},1500);
|
||
|
});
|
||
|
|
||
|
clipboard.on('error', function(e) {
|
||
|
that.text('复制完成');
|
||
|
alert('此浏览器不支持此操作,请长按礼包码复制');
|
||
|
});
|
||
|
}
|
||
|
|
||
|
|
||
|
|
||
|
$(function() {
|
||
|
new Swiper('#banner-carousel', {autoplay:{delay:2000},loop:true,
|
||
|
// 如果需要分页器
|
||
|
pagination: {
|
||
|
el: '.swiper-pagination',
|
||
|
},
|
||
|
});
|
||
|
$('.goto').click(function(){
|
||
|
var url = $(this).attr("date-value");
|
||
|
if(url == '')return false;
|
||
|
var game_id = $(this).attr("date-id");
|
||
|
var promote_id = $(this).attr("date-promote");
|
||
|
$.ajax({
|
||
|
type:'GET',
|
||
|
dataType:'json',
|
||
|
url:'{:U("Game/setdownload")}',
|
||
|
data:{game_id:game_id,promote_id:promote_id},
|
||
|
success:function(data) {
|
||
|
},
|
||
|
});
|
||
|
window.location.href = url;
|
||
|
})
|
||
|
function isWeiXin(){
|
||
|
var ua = window.navigator.userAgent.toLowerCase();
|
||
|
if(ua.match(/MicroMessenger/i) == 'micromessenger'){
|
||
|
return true;
|
||
|
}else{
|
||
|
return false;
|
||
|
}
|
||
|
}
|
||
|
$('.jschatqq').click(function() {
|
||
|
if(isWeiXin()){
|
||
|
layer.msg('请浏览器打开此页面联系客服');
|
||
|
}else{
|
||
|
var qq = $.trim($(this).attr('data-value'));
|
||
|
if (browser.versions.mobile) {
|
||
|
window.location.href="mqqwpa://im/chat?chat_type=wpa&uin="+qq+"&version=1&src_type=web";
|
||
|
}else
|
||
|
window.location.href="http://wpa.qq.com/msgrd?v=3&uin="+qq+"&site=qq&menu=yes";
|
||
|
return false;
|
||
|
}
|
||
|
});
|
||
|
|
||
|
$('.jschatqqqun').click(function() {
|
||
|
var qq = $.trim($(this).attr('data-value'));
|
||
|
if (browser.versions.mobile) {
|
||
|
var url = $.trim($(this).attr('data-url'));
|
||
|
if (url) {
|
||
|
window.location.href=url;
|
||
|
}else {
|
||
|
layer.msg('暂无此群');
|
||
|
}
|
||
|
|
||
|
}else {
|
||
|
if (qq) {
|
||
|
window.location.href="mqqapi://card/show_pslcard?src_type=internal&version=1&uin="+qq+"&card_type=group&source=external";
|
||
|
} else {
|
||
|
layer.msg('暂无此群');
|
||
|
}
|
||
|
}
|
||
|
return false;
|
||
|
});
|
||
|
|
||
|
|
||
|
$('.jsgetgift').on('click',function() {
|
||
|
var that=$(this),id=$.trim(that.attr('data-id')),text = $.trim(that.text());
|
||
|
if (id>0) {
|
||
|
if (that.hasClass('disabled')) {return false;}
|
||
|
that.addClass('disabled').text('领取中');
|
||
|
|
||
|
$.ajax({
|
||
|
type:'post',
|
||
|
dataType:'json',
|
||
|
url:'{:U("Gift/getgift")}',
|
||
|
data:{id:id},
|
||
|
success:function(data) {
|
||
|
switch(parseInt(data.status)) {
|
||
|
case 1:
|
||
|
case 2:
|
||
|
case 3:{
|
||
|
that.text('已领取');
|
||
|
var title = parseInt(data.status)==2?'你已成功领取过':'领取成功!';
|
||
|
layer.open({
|
||
|
type: 1,
|
||
|
closeBtn: '1',
|
||
|
title: false,
|
||
|
skin: 'layer-lwx-style', //加上边框
|
||
|
area: ['7rem', '3.5rem'], //宽高
|
||
|
content: '<div class="layer-lwx-notice"><h4 class="layer-lwx-title">'+title+'</h4><p class="layer-lwx-novice"><span>激活码:</span><span class="novice-txt">'+data.info+'</span></p><div class="layer-lwx-butn"><a href="javascript:;" class="butn copy">复制激活码</a></div></div>',
|
||
|
success:function(layero, index){
|
||
|
|
||
|
$('.copy').click(function() {
|
||
|
// //移动端复制
|
||
|
$(".copy").text('复制成功');
|
||
|
Copy($('.novice-txt').text(),$(this),index);
|
||
|
|
||
|
return false;
|
||
|
});
|
||
|
}
|
||
|
});
|
||
|
};break;
|
||
|
case 4:{
|
||
|
that.text('已领完');
|
||
|
layer.msg(data.info);
|
||
|
};break;
|
||
|
default:{layer.msg(data.info);
|
||
|
that.removeClass('disabled').text(text);}
|
||
|
|
||
|
}
|
||
|
},error:function() {
|
||
|
layer.msg('服务器故障,请稍候再试...');
|
||
|
that.removeClass('disabled').text(text);
|
||
|
}
|
||
|
});
|
||
|
|
||
|
}
|
||
|
|
||
|
return false;
|
||
|
});
|
||
|
|
||
|
});
|
||
|
</script>
|
||
|
</block>
|