Initial project files: BESCMS full source
This commit is contained in:
@@ -0,0 +1,27 @@
|
||||
{template "header.html"}
|
||||
<header class="hui-header">
|
||||
<div id="hui-back"></div>
|
||||
<h1>404错误</h1>
|
||||
<a id="hui-search" href="javascript:dr_m_top_search();"><i class="fa fa-search"></i></a>
|
||||
</header>
|
||||
<div class="hui-header-line"></div>
|
||||
|
||||
<div class="page-content">
|
||||
|
||||
<div class="text-center fc-msg-body">
|
||||
|
||||
|
||||
|
||||
<div class="fc-msg-info">
|
||||
<label class="fc-msg-title">{$msg}</label>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
{template "footer.html"}
|
||||
@@ -0,0 +1,54 @@
|
||||
{template "header.html"}
|
||||
<header class="hui-header">
|
||||
<div id="hui-back"></div>
|
||||
<h1>{$cat.name}</h1>
|
||||
<a id="hui-search" href="javascript:dr_m_top_category();"><i class="fa fa-navicon"></i></a>
|
||||
</header>
|
||||
<div class="hui-header-line"></div>
|
||||
|
||||
<div class="search-page search-content-1 margin-top-20">
|
||||
|
||||
|
||||
<!--循环输出顶级栏目下面的子栏目及其内容,运用到了双list循环标签因此需要定义返回值return=c(都懂得)-->
|
||||
{category pid=$catid return=c}
|
||||
|
||||
<div class="portlet light">
|
||||
<div class="portlet-title">
|
||||
<div class="caption">
|
||||
<span class="caption-subject bold uppercase"><a class=" font-green" href="{$c.url}">{$c.name}</a></span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="portlet-body">
|
||||
|
||||
<div class="search-container">
|
||||
<ul>
|
||||
{module module=MOD_DIR catid=$c.id order=updatetime num=10}
|
||||
<li class="search-item clearfix">
|
||||
<a title="{$t.title}" href="{$t.url}">
|
||||
<img src="{dr_thumb($t.thumb, 100, 90)}" width="100" height="90" style="margin-top: 15px;">
|
||||
</a>
|
||||
<div class="search-content text-left">
|
||||
<h4 class="search-title">
|
||||
<a title="{$t.title}" href="{$t.url}">{dr_strcut($t.title, 20)}</a>
|
||||
</h4>
|
||||
<p class="search-desc">{dr_strcut($t.description, 44)}</p>
|
||||
</div>
|
||||
<div class="search-post-foot">
|
||||
<a href="{dr_cat_value('news',$t.catid, 'url')}"><i class="fa fa-list"></i> {dr_cat_value('news',$t.catid, 'name')}</a>
|
||||
<a href="{$t.url}"><i class="fa fa-calendar"></i> {$t.updatetime}</a>
|
||||
</div>
|
||||
</li>
|
||||
{/module}
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{/category}
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
{template "footer.html"}
|
||||
@@ -0,0 +1,18 @@
|
||||
|
||||
<div class="page-wrapper-row margin-top-20">
|
||||
<div class="page-wrapper-bottom">
|
||||
<!-- BEGIN FOOTER -->
|
||||
<div class="page-footer">
|
||||
<div class="container"> {date('Y')} © {SITE_NAME}
|
||||
{SITE_TONGJI}
|
||||
</div>
|
||||
</div>
|
||||
<div class="scroll-to-top">
|
||||
<i class="fa fa-arrow-up"></i>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</body>
|
||||
|
||||
</html>
|
||||
@@ -0,0 +1,122 @@
|
||||
<!DOCTYPE html>
|
||||
<!--[if !IE]><!-->
|
||||
<html lang="zh-cn">
|
||||
<!--<![endif]-->
|
||||
<head>
|
||||
<meta charset="utf-8" />
|
||||
<title>{$meta_title}</title>
|
||||
<meta content="{$meta_keywords}" name="keywords" />
|
||||
<meta content="{$meta_description}" name="description" />
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<meta content="width=device-width, initial-scale=1" name="viewport" />
|
||||
<!-- 主要css开始 -->
|
||||
<link href="{THEME_PATH}assets/icon/css/icon.css" rel="stylesheet" type="text/css" />
|
||||
<link href="{THEME_PATH}assets/global/css/admin.min.css" rel="stylesheet" type="text/css" />
|
||||
<!-- 主要css结束 -->
|
||||
<!-- 风格css开始 -->
|
||||
<link href="{HOME_THEME_PATH}web/css/style.css" rel="stylesheet" type="text/css" />
|
||||
<!-- 风格css结束 -->
|
||||
<link rel="stylesheet" type="text/css" href="{MOBILE_THEME_PATH}css/mobile.css" />
|
||||
<!-- 系统懒人版js(所有自建模板引用) -->
|
||||
<script type="text/javascript">var is_mobile_cms = '1';var web_dir = '{WEB_DIR}';</script>
|
||||
<script src="{LANG_PATH}lang.js" type="text/javascript"></script>
|
||||
<script src="{ROOT_THEME_PATH}assets/global/plugins/jquery.min.js" type="text/javascript"></script>
|
||||
<script src="{ROOT_THEME_PATH}assets/js/cms.js" type="text/javascript"></script>
|
||||
<!-- 系统懒人版js结束 -->
|
||||
<script src="{ROOT_THEME_PATH}assets/global/plugins/bootstrap/js/bootstrap.min.js" type="text/javascript"></script>
|
||||
<script src="{HOME_THEME_PATH}web/scripts/app.min.js" type="text/javascript"></script>
|
||||
<script src="{MOBILE_THEME_PATH}js/mobile.js" type="text/javascript"></script>
|
||||
|
||||
</head>
|
||||
<body class="page-container-bg-solid">
|
||||
<div class="top-category-menu" style="display: none">
|
||||
<div class="top-category-back" onclick="dr_m_top_category2()">
|
||||
<i class="fa fa-angle-left"></i> 返回
|
||||
</div>
|
||||
<div class="top-category-list">
|
||||
<div class="p1-nav">
|
||||
<h5><a href="{SITE_MURL}">首页</a></h5>
|
||||
</div>
|
||||
<!--调用共享栏目-->
|
||||
<!--第一层:调用pid=0表示顶级-->
|
||||
{category module=share pid=0}
|
||||
<div class="p1-nav">
|
||||
<h5><a href="{$t.url}" class="{if IS_SHARE && dr_in_array($catid, $t.catids)} active{/if}" title="{$t.name}">{$t.name}</a></h5>
|
||||
{if $t.child}
|
||||
<div class="p2-nav">
|
||||
<!--第二层-->
|
||||
{category module=share pid=$t.id return=t2}
|
||||
<a href="{$t2.url}" class="{if IS_SHARE && $catid && dr_in_array($catid, $t2.catids)} active{/if}" title="{$t2.name}">{$t2.name}</a>
|
||||
{/category}
|
||||
</div>
|
||||
<div class="clearfix"></div>
|
||||
{/if}
|
||||
</div>
|
||||
{/category}
|
||||
|
||||
<!--调用全部独立模块-->
|
||||
{cache name=module-content return=m}
|
||||
{if !$m.share}
|
||||
<div class="p1-nav">
|
||||
<h5><a href="{$m.url}" class="{if MOD_DIR==$m.dirname}active{/if}" title="{$m.name}">{$m.name}</a></h5>
|
||||
{if $t.child}
|
||||
<div class="p2-nav">
|
||||
<!--调用独立模块下的栏目-->
|
||||
{category module=$m.dirname pid=0 return=t2}
|
||||
<a href="{$t2.url}" class="{if MOD_DIR==$m.dirname && $catid && dr_in_array($catid, $t2.catids)} active{/if}" title="{$t2.name}">{$t2.name}</a>
|
||||
{/category}
|
||||
</div>
|
||||
<div class="clearfix"></div>
|
||||
{/if}
|
||||
</div>
|
||||
|
||||
|
||||
{/if}
|
||||
{/cache}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="top-search-menu" style="display: none">
|
||||
<div class="top-search-back" onclick="dr_m_top_search2()">
|
||||
<i class="fa fa-angle-left"></i> 返回
|
||||
</div>
|
||||
<div class="top-search-list">
|
||||
|
||||
<form class="search-form" action="{SITE_MURL}index.php" method="get">
|
||||
<input type="hidden" name="s" value="api">
|
||||
<input type="hidden" name="c" value="api">
|
||||
<input type="hidden" name="m" value="search">
|
||||
<input type="hidden" name="dir" id="dr_search_module_dir" >
|
||||
<div class="input-group">
|
||||
<div class="input-group-btn btn-group">
|
||||
<button id="dr_search_module_name" type="button" class="btn default dropdown-toggle" data-toggle="dropdown" aria-expanded="false">
|
||||
<i class="fa fa-angle-down"></i>
|
||||
</button>
|
||||
<ul class="dropdown-menu">
|
||||
<!--这是来列出全部可以搜索的内容模块-->
|
||||
{php $top_search=[];}
|
||||
{cache name=module-content}
|
||||
{if $t.search}
|
||||
{php !$top_search && $top_search=$t;}
|
||||
<li><a href="javascript:dr_search_module_select('{$t.dirname}', '{$t.name}');"> {$t.name} </a></li>
|
||||
{/if}
|
||||
{/cache}
|
||||
</ul>
|
||||
</div>
|
||||
<input type="text" placeholder="搜索内容..." name="keyword" class="fc-search-keyword form-control">
|
||||
<div class="input-group-btn">
|
||||
<button class="btn default" type="submit"> 搜索 </button>
|
||||
</div>
|
||||
</div>
|
||||
<script>
|
||||
// 这段js是用来执行搜索的
|
||||
function dr_search_module_select(dir, name) {
|
||||
$("#dr_search_module_dir").val(dir);
|
||||
$("#dr_search_module_name").html(name+' <i class="fa fa-angle-down"></i>');
|
||||
}
|
||||
dr_search_module_select('{php echo MOD_DIR ? MOD_DIR : $top_search.dirname}', '{php echo MOD_DIR ? MODULE_NAME : $top_search.name}');
|
||||
</script>
|
||||
</form>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1,72 @@
|
||||
{template "header.html"}
|
||||
<header class="hui-header">
|
||||
<a id="hui-member" href="{SITE_MURL}"><i class="fa fa-home"></i></a>
|
||||
<h1>首页</h1>
|
||||
<a id="hui-search" href="javascript:dr_m_top_search();"><i class="fa fa-search"></i></a>
|
||||
</header>
|
||||
<div class="category-nav">
|
||||
<ul>
|
||||
<!--调用共享栏目-->
|
||||
<!--第一层:调用pid=0表示顶级-->
|
||||
{category module=share pid=0}
|
||||
<li class="{if IS_SHARE && $catid && dr_in_array($catid, $t.catids)} active{/if}">
|
||||
<a href="{$t.url}" title="{$t.name}">{$t.name}</a>
|
||||
</li>
|
||||
{/category}
|
||||
</ul>
|
||||
<a class="category-more" href="javascript:dr_m_top_category();"><i class="fa fa-angle-down"></i></a>
|
||||
</div>
|
||||
|
||||
<div class="hui-index-header-line"></div>
|
||||
|
||||
<div id="myCarousel" class="carousel slide" data-ride="carousel">
|
||||
<!-- 幻灯图片 -->
|
||||
<div class="carousel-inner">
|
||||
<!-- 调用news模块的前5张图片 -->
|
||||
{module module=news thumb=1 num=5}
|
||||
<div class="item {if $key==0}active{/if}">
|
||||
<a href="{$t.url}" target="_blank"><img src="{dr_get_file($t.thumb)}" style="width:360px;height:245px" /></a>
|
||||
</div>
|
||||
{/module}
|
||||
</div>
|
||||
<ol class="carousel-indicators">
|
||||
<!-- 重复读取上面循环的变量,避免重复查询第二次 -->
|
||||
{loop $return $key $t}
|
||||
<li data-target="#myCarousel" data-slide-to="{$key}" class="active"></li>
|
||||
{/loop}
|
||||
</ol>
|
||||
</div>
|
||||
|
||||
<div class="page-content">
|
||||
|
||||
<div class="search-page search-content-1">
|
||||
|
||||
<div class="search-container">
|
||||
<ul class="search-container">
|
||||
<!--分页显示列表数据-->
|
||||
{module module=news order=updatetime num=10}
|
||||
<li class="search-item clearfix">
|
||||
<a title="{$t.title}" href="{$t.url}">
|
||||
<img src="{dr_thumb($t.thumb, 100, 90)}" width="100" height="90" style="margin-top: 15px;">
|
||||
</a>
|
||||
<div class="search-content text-left">
|
||||
<h4 class="search-title">
|
||||
<a title="{$t.title}" href="{$t.url}">{dr_strcut($t.title, 20)}</a>
|
||||
</h4>
|
||||
<p class="search-desc">{dr_strcut($t.description, 44)}</p>
|
||||
</div>
|
||||
<div class="search-post-foot">
|
||||
<a href="{dr_cat_value('news',$t.catid, 'url')}"><i class="fa fa-list"></i> {dr_cat_value('news',$t.catid, 'name')}</a>
|
||||
<a href="{$t.url}"><i class="fa fa-calendar"></i> {$t.updatetime}</a>
|
||||
</div>
|
||||
</li>
|
||||
{/module}
|
||||
</ul>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
{template "footer.html"}
|
||||
@@ -0,0 +1,63 @@
|
||||
{template "header.html"}
|
||||
|
||||
<header class="hui-header">
|
||||
<div id="hui-back"></div>
|
||||
<h1>{$cat.name}</h1>
|
||||
<a id="hui-search" href="javascript:dr_m_top_category();"><i class="fa fa-navicon"></i></a>
|
||||
</header>
|
||||
<div class="hui-header-line"></div>
|
||||
|
||||
|
||||
|
||||
<div class="page-content">
|
||||
|
||||
<div class="search-page search-content-1">
|
||||
|
||||
<div class="search-container">
|
||||
<!--分页显示列表数据-->
|
||||
<ul class="search-container" id="content_list">
|
||||
{template "list_data.html"}
|
||||
</ul>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="margin-top-20" id="is_ajax_btn">
|
||||
<a href="javascript:dr_ajax_load_more();" class="btn default btn-block"> 加载更多 </a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<script>
|
||||
var Mpage=1;
|
||||
//滚动显示更多
|
||||
var scroll_get = true; //做个标志,不要反反复复的加载
|
||||
$(document).ready(function () {
|
||||
$(window).scroll(function () {
|
||||
if (scroll_get==true && (400 + $(window).scrollTop())>($(document).height() - $(window).height())) {
|
||||
scroll_get = false;
|
||||
layer.msg('内容加截中,请稍候',{time:1000});
|
||||
dr_ajax_load_more();
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
function dr_ajax_load_more(){
|
||||
Mpage++;
|
||||
$.get('/index.php?s=api&c=api&m=template&name=list_data.html&module={MOD_DIR}&catid={$catid}&format=json&page='+Mpage+'&'+Math.random(),function(res){
|
||||
$('.footer-cont').hide();
|
||||
if(res.code==1){
|
||||
if(res.msg==''){
|
||||
$('#is_ajax_btn').hide();
|
||||
layer.msg("已经显示完了",{time:500});
|
||||
}else{
|
||||
$('#content_list').append(res.msg);
|
||||
scroll_get = true;
|
||||
}
|
||||
}else{
|
||||
layer.msg(res.msg,{time:2500});
|
||||
}
|
||||
}, 'json');
|
||||
}
|
||||
</script>
|
||||
{template "footer.html"}
|
||||
@@ -0,0 +1,18 @@
|
||||
{php $catid=intval($catid);}
|
||||
{module catid=$catid order=updatetime page=1}
|
||||
<li class="search-item clearfix">
|
||||
<a title="{$t.title}" href="{$t.url}">
|
||||
<img src="{dr_thumb($t.thumb, 100, 90)}" width="100" height="90" style="margin-top: 15px;">
|
||||
</a>
|
||||
<div class="search-content text-left">
|
||||
<h4 class="search-title">
|
||||
<a title="{$t.title}" href="{$t.url}">{dr_strcut($t.title, 20)}</a>
|
||||
</h4>
|
||||
<p class="search-desc">{dr_strcut($t.description, 44)}</p>
|
||||
</div>
|
||||
<div class="search-post-foot">
|
||||
<a href="{dr_cat_value($t.catid, 'url')}"><i class="fa fa-list"></i> {dr_cat_value($t.catid, 'name')}</a>
|
||||
<a href="{$t.url}"><i class="fa fa-calendar"></i> {$t.updatetime}</a>
|
||||
</div>
|
||||
</li>
|
||||
{/module}
|
||||
@@ -0,0 +1,30 @@
|
||||
{template "header.html"}
|
||||
|
||||
<header class="hui-header">
|
||||
<div id="hui-back"></div>
|
||||
<h1>这里是模块表单列表页</h1>
|
||||
<a id="hui-search" href="javascript:dr_m_top_category();"><i class="fa fa-navicon"></i></a>
|
||||
</header>
|
||||
<div class="hui-header-line"></div>
|
||||
|
||||
<div class="page-wrapper-row full-height">
|
||||
<div class="portlet-body">
|
||||
|
||||
|
||||
<ul class="list-unstyled fc-list-form">
|
||||
{mform form=$form_table cid=$index.id page=1 urlrule=$urlrule pagesize=5}
|
||||
<li>
|
||||
<a href="{Router::mform_show_url($form_table, $t.id)}" class="title">{dr_strcut($t.title, 60)}</a>
|
||||
<span>{$t.inputtime}</span>
|
||||
</li>
|
||||
{/mform}
|
||||
</ul>
|
||||
|
||||
<div class="search-pagination text-center margin-top-30">
|
||||
{$pages}
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{template "footer.html"}
|
||||
@@ -0,0 +1,42 @@
|
||||
{template "header.html"}
|
||||
<header class="hui-header">
|
||||
<div id="hui-back"></div>
|
||||
<h1>这里是{MODULE_NAME}模块表单提交页</h1>
|
||||
<a id="hui-search" href="javascript:dr_m_top_category();"><i class="fa fa-navicon"></i></a>
|
||||
</header>
|
||||
<div class="hui-header-line"></div>
|
||||
|
||||
<div class="page-wrapper-row full-height">
|
||||
<form action="" class="form-horizontal" method="post" name="myform" id="myform">
|
||||
{$form}
|
||||
<div class="fc-form-body">
|
||||
{$myfield}
|
||||
{$diyfield}
|
||||
{if $is_post_code}
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-2">{dr_lang('验证码')}</label>
|
||||
<div class="col-md-9">
|
||||
<label>
|
||||
<div class="form-recaptcha">
|
||||
<div class="input-group">
|
||||
<input type="text" class="form-control" name="code">
|
||||
<div class="input-group-btn fc-code">
|
||||
{dr_code(120, 35)}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
{/if}
|
||||
</div>
|
||||
|
||||
<div class="portlet-body form myfooter">
|
||||
<div class="form-actions text-center">
|
||||
<button type="button" onclick="dr_ajax_submit('{dr_now_url()}', 'myform', '2000', '{$rt_url}')" class="btn green"> <i class="fa fa-save"></i> 提交内容</button>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
|
||||
{template "footer.html"}
|
||||
@@ -0,0 +1,24 @@
|
||||
{template "header.html"}
|
||||
<header class="hui-header">
|
||||
<div id="hui-back"></div>
|
||||
<h1>这里是{MODULE_NAME}模块表单详情页</h1>
|
||||
<a id="hui-search" href="javascript:dr_m_top_category();"><i class="fa fa-navicon"></i></a>
|
||||
</header>
|
||||
<div class="hui-header-line"></div>
|
||||
<div class="page-content-inner">
|
||||
<div class="portlet light">
|
||||
<div class="portlet-title">
|
||||
<div class="caption">
|
||||
<span class="caption-subject "> {$form_name}: {$index.title} </span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="portlet-body">
|
||||
|
||||
{$myfield}
|
||||
{$diyfield}
|
||||
{$sysfield}
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{template "footer.html"}
|
||||
@@ -0,0 +1,185 @@
|
||||
<!DOCTYPE html>
|
||||
<!--[if IE 8]> <html lang="zh-cn" class="ie8 no-js"> <![endif]-->
|
||||
<!--[if IE 9]> <html lang="zh-cn" class="ie9 no-js"> <![endif]-->
|
||||
<!--[if !IE]><!-->
|
||||
<html lang="zh-cn">
|
||||
<!--<![endif]-->
|
||||
<head>
|
||||
<meta charset="utf-8" />
|
||||
<title>{$meta_title}</title>
|
||||
<meta content="{$meta_keywords}" name="keywords" />
|
||||
<meta content="{$meta_description}" name="description" />
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<meta content="width=device-width, initial-scale=1" name="viewport" />
|
||||
<!-- 主要css开始 -->
|
||||
<link href="{THEME_PATH}assets/icon/css/icon.css" rel="stylesheet" type="text/css" />
|
||||
<link href="{THEME_PATH}assets/global/css/cms.css" rel="stylesheet" type="text/css" />
|
||||
<!-- 主要css结束 -->
|
||||
<!-- 风格css开始 -->
|
||||
<link href="{HOME_THEME_PATH}web/css/style.css" rel="stylesheet" type="text/css" />
|
||||
<!-- 风格css结束 -->
|
||||
<link rel="stylesheet" type="text/css" href="{MOBILE_THEME_PATH}css/mobile.css" />
|
||||
<!--[if lt IE 9]>
|
||||
<script src="{ROOT_THEME_PATH}assets/global/plugins/respond.min.js"></script>
|
||||
<script src="{ROOT_THEME_PATH}assets/global/plugins/excanvas.min.js"></script>
|
||||
<![endif]-->
|
||||
<!-- 系统关键js(所有自建模板必须引用) -->
|
||||
<script type="text/javascript">var is_mobile_cms = '1';</script>
|
||||
<script src="{LANG_PATH}lang.js" type="text/javascript"></script>
|
||||
<script src="{ROOT_THEME_PATH}assets/global/plugins/jquery.min.js" type="text/javascript"></script>
|
||||
<script src="{ROOT_THEME_PATH}assets/js/cms.js" type="text/javascript"></script>
|
||||
<!-- 系统关键js结束 -->
|
||||
<script src="{ROOT_THEME_PATH}assets/global/plugins/bootstrap/js/bootstrap.min.js" type="text/javascript"></script>
|
||||
<script src="{HOME_THEME_PATH}web/scripts/app.min.js" type="text/javascript"></script>
|
||||
<script src="{MOBILE_THEME_PATH}js/mobile.js" type="text/javascript"></script>
|
||||
|
||||
</head>
|
||||
<body class="page-container-bg-solid">
|
||||
<div class="top-category-menu" style="display: none">
|
||||
<div class="top-category-back" onclick="dr_m_top_category2()">
|
||||
<i class="fa fa-angle-left"></i> 返回
|
||||
</div>
|
||||
<div class="top-category-list">
|
||||
<div class="p1-nav">
|
||||
<h5><a href="/">首页</a></h5>
|
||||
</div>
|
||||
<!--调用共享栏目-->
|
||||
<!--第一层:调用pid=0表示顶级-->
|
||||
{category module=share pid=0}
|
||||
<div class="p1-nav">
|
||||
<h5><a href="{$t.url}" class="{if IS_SHARE && dr_in_array($catid, $t.catids)} active{/if}" title="{$t.name}">{$t.name}</a></h5>
|
||||
{if $t.child}
|
||||
<div class="p2-nav">
|
||||
<!--第二层-->
|
||||
{category module=share pid=$t.id return=t2}
|
||||
<a href="{$t2.url}" class="{if IS_SHARE && $catid && dr_in_array($catid, $t2.catids)} active{/if}" title="{$t2.name}">{$t2.name}</a>
|
||||
{/category}
|
||||
</div>
|
||||
<div class="clearfix"></div>
|
||||
{/if}
|
||||
</div>
|
||||
{/category}
|
||||
|
||||
<!--调用全部独立模块-->
|
||||
{cache name=module-content return=m}
|
||||
{if !$m.share}
|
||||
<div class="p1-nav">
|
||||
<h5><a href="{$m.url}" class="{if MOD_DIR==$m.dirname}active{/if}" title="{$m.name}">{$m.name}</a></h5>
|
||||
{if $t.child}
|
||||
<div class="p2-nav">
|
||||
<!--调用独立模块下的栏目-->
|
||||
{category module=$m.dirname pid=0 return=t2}
|
||||
<a href="{$t2.url}" class="{if MOD_DIR==$m.dirname && $catid && dr_in_array($catid, $t2.catids)} active{/if}" title="{$t2.name}">{$t2.name}</a>
|
||||
{/category}
|
||||
</div>
|
||||
<div class="clearfix"></div>
|
||||
{/if}
|
||||
</div>
|
||||
|
||||
|
||||
{/if}
|
||||
{/cache}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="top-search-menu" style="display: none">
|
||||
<div class="top-search-back" onclick="dr_m_top_search2()">
|
||||
<i class="fa fa-angle-left"></i> 返回
|
||||
</div>
|
||||
<div class="top-search-list">
|
||||
|
||||
<form class="search-form" action="/index.php" method="get">
|
||||
<input type="hidden" name="s" value="api">
|
||||
<input type="hidden" name="c" value="api">
|
||||
<input type="hidden" name="m" value="search">
|
||||
<input type="hidden" name="dir" id="dr_search_module_dir" >
|
||||
<div class="input-group">
|
||||
<div class="input-group-btn btn-group">
|
||||
<button id="dr_search_module_name" type="button" class="btn default dropdown-toggle" data-toggle="dropdown" aria-expanded="false">
|
||||
<i class="fa fa-angle-down"></i>
|
||||
</button>
|
||||
<ul class="dropdown-menu">
|
||||
<!--这是来列出全部可以搜索的内容模块-->
|
||||
{php $top_search=[];}
|
||||
{cache name=module-content}
|
||||
{if $t.search}
|
||||
{php !$top_search && $top_search=$t;}
|
||||
<li><a href="javascript:dr_search_module_select('{$t.dirname}', '{$t.name}');"> {$t.name} </a></li>
|
||||
{/if}
|
||||
{/cache}
|
||||
</ul>
|
||||
</div>
|
||||
<input type="text" placeholder="搜索内容..." name="keyword" class="fc-search-keyword form-control">
|
||||
<div class="input-group-btn">
|
||||
<button class="btn default" type="submit"> 搜索 </button>
|
||||
</div>
|
||||
</div>
|
||||
<script>
|
||||
// 这段js是用来执行搜索的
|
||||
function dr_search_module_select(dir, name) {
|
||||
$("#dr_search_module_dir").val(dir);
|
||||
$("#dr_search_module_name").html(name+' <i class="fa fa-angle-down"></i>');
|
||||
}
|
||||
dr_search_module_select('{php echo MOD_DIR ? MOD_DIR : $top_search.dirname}', '{php echo MOD_DIR ? MODULE_NAME : $top_search.name}');
|
||||
</script>
|
||||
</form>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<header class="hui-header">
|
||||
<div id="hui-back"></div>
|
||||
<h1>提示信息</h1>
|
||||
<a id="hui-search" href="javascript:dr_m_top_category();"><i class="fa fa-navicon"></i></a>
|
||||
</header>
|
||||
<div class="hui-header-line"></div>
|
||||
|
||||
<div class="page-content">
|
||||
|
||||
<div class="text-center fc-msg-body">
|
||||
|
||||
|
||||
<div class="fc-msg-icon">
|
||||
{if $code}
|
||||
<i class="fa fa-info fc-msg-icon"></i>
|
||||
{else}
|
||||
<i class="fa fa-close fc-msg-icon"></i>
|
||||
{/if}
|
||||
</div>
|
||||
|
||||
<div class="fc-msg-info">
|
||||
<label class="fc-msg-title">{$msg}</label>
|
||||
|
||||
</div>
|
||||
<div class="fc-msg-url">
|
||||
{if $url}
|
||||
<a href="{$url}">如果您的浏览器没有自动跳转,请点击这里</a>
|
||||
<meta http-equiv="refresh" content="{$time}; url={$url}">
|
||||
{else}
|
||||
<a href="{$backurl}" >[点击返回上一页]</a>
|
||||
{/if}
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<div class="page-wrapper-row margin-top-20">
|
||||
<div class="page-wrapper-bottom">
|
||||
<!-- BEGIN FOOTER -->
|
||||
<div class="page-footer">
|
||||
<div class="container"> {date('Y')} © {SITE_NAME}
|
||||
<a target="_blank" href="{SITE_URL}">{SITE_ICP}</a>
|
||||
{SITE_TONGJI}
|
||||
</div>
|
||||
</div>
|
||||
<div class="scroll-to-top">
|
||||
<i class="fa fa-arrow-up"></i>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</body>
|
||||
|
||||
</html>
|
||||
@@ -0,0 +1,17 @@
|
||||
{template "header.html"}
|
||||
<header class="hui-header">
|
||||
<div id="hui-back"></div>
|
||||
<h1>{$cat.name}</h1>
|
||||
<a id="hui-search" href="javascript:dr_m_top_category();"><i class="fa fa-navicon"></i></a>
|
||||
</header>
|
||||
|
||||
<div class="page-wrapper-row full-height margin-top-20">
|
||||
<div class="portlet light margin-top-20">
|
||||
<div class="portlet-body xrcontent margin-top-40">
|
||||
{dr_text_rel($content)}
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{template "footer.html"}
|
||||
@@ -0,0 +1,130 @@
|
||||
{template "header.html"}
|
||||
<header class="hui-header">
|
||||
<div id="hui-back"></div>
|
||||
<h1>内容搜索页面</h1>
|
||||
<a id="hui-search" href="javascript:dr_m_top_category();"><i class="fa fa-navicon"></i></a>
|
||||
</header>
|
||||
<div class="hui-header-line"></div>
|
||||
|
||||
|
||||
<div class="search-page search-content-1">
|
||||
|
||||
<div class="portlet light">
|
||||
|
||||
<div class="portlet-body form fc-search-param">
|
||||
<div class="form-body">
|
||||
<div class="form-group row">
|
||||
<label class="col-md-12">栏目分类</label>
|
||||
<div class="col-md-9">
|
||||
<label><a class="label {if !$cat || $cat.child}label-success{else}label-default{/if}" href="{Router::search_url($params, 'catid', NULL)}">不限</a></label>
|
||||
<!--调用栏目分类,这种用法只能用于模块列表与搜索页面-->
|
||||
{loop $related $t}
|
||||
<label><a class="label {if $t.id==$cat.id}label-success{else}label-default{/if}" href="{Router::search_url($params, 'catid', $t.id)}">{$t.name}</a></label>
|
||||
{/loop}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!--category_search_field是调用当前栏目下的附加字段是否具有搜索字段功能,这种用法只能用于模块列表与搜索页面-->
|
||||
{category_search_field module=MOD_DIR catid=$catid}
|
||||
<div class="form-group row">
|
||||
<label class="col-md-12">{$t.name}</label>
|
||||
<div class="col-md-9">
|
||||
<label><a class="label {if !$params[$t.field]}label-success{else}label-default{/if}" href="{Router::search_url($params, $t.field, NULL)}">不限</a></label>
|
||||
{loop $t.data $v}
|
||||
<label><a class="label {if $v.value==$params[$t.field]}label-success{else}label-default{/if}" href="{Router::search_url($params, $t.field, $v.value)}">{$v.name}</a></label>
|
||||
{/loop}
|
||||
</div>
|
||||
</div>
|
||||
{/category_search_field}
|
||||
|
||||
<!--按关键字搜索-->
|
||||
<div class="form-group row">
|
||||
<label class="col-md-12" style="padding-top:5px">内容搜索</label>
|
||||
<div class="col-md-6">
|
||||
<div class="input-group">
|
||||
<input type="text" class="form-control" onkeypress="if(event.keyCode==13) {dr_module_search('search_keyword');return false;}" name='keyword' value='{$keyword}' id='search_keyword'>
|
||||
<span class="input-group-btn">
|
||||
<button class="btn blue" onclick="dr_module_search('search_keyword')" type="button"> <i class="fa fa-search"></i> 搜索</button>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script>
|
||||
// 这段js是用来执行搜索的
|
||||
function dr_module_search(name) {
|
||||
var url="{Router::search_url($params, 'keyword', 'dayrui')}";
|
||||
var value = $("#"+name).val();
|
||||
if (value) {
|
||||
location.href=url.replace('dayrui', value);
|
||||
} else {
|
||||
$("#"+name).focus()
|
||||
dr_tips(0, "输入关键字");
|
||||
}
|
||||
return false;
|
||||
}
|
||||
</script>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div class="portlet-body search-container ">
|
||||
<ul class="search-container" id="content_list">
|
||||
{template "search_data.html"}
|
||||
</ul>
|
||||
|
||||
{if !$count}
|
||||
<div class="row fc-search-null">
|
||||
<div class="col-md-12 text-center">
|
||||
<i class="fa fa-close fc-search-null-icon"></i>
|
||||
<label class="fc-search-null-txt">没有找到相关内容...</label>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
{else}
|
||||
<div class="margin-top-20" id="is_ajax_btn">
|
||||
<a href="javascript:dr_ajax_load_more();" class="btn default btn-block"> 加载更多 </a>
|
||||
</div>
|
||||
{/if}
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
<script>
|
||||
var Mpage=1;
|
||||
//滚动显示更多
|
||||
var scroll_get = true; //做个标志,不要反反复复的加载
|
||||
$(document).ready(function () {
|
||||
$(window).scroll(function () {
|
||||
if (scroll_get==true && (400 + $(window).scrollTop())>($(document).height() - $(window).height())) {
|
||||
scroll_get = false;
|
||||
layer.msg('内容加截中,请稍候',{time:1000});
|
||||
dr_ajax_load_more();
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
function dr_ajax_load_more(){
|
||||
Mpage++;
|
||||
$.get('/index.php?s=api&c=api&m=template&name=search_data.html&module={MOD_DIR}&catid={$catid}&searchid={$searchid}&sototal={$sototal}&order={$params.order}&format=json&page='+Mpage+'&'+Math.random(),function(res){
|
||||
$('.footer-cont').hide();
|
||||
if(res.code==1){
|
||||
if(res.msg==''){
|
||||
layer.msg("已经显示完了",{time:500});
|
||||
$('#is_ajax_btn').hide();
|
||||
}else{
|
||||
$('#content_list').append(res.msg);
|
||||
scroll_get = true;
|
||||
}
|
||||
}else{
|
||||
layer.msg(res.msg,{time:2500});
|
||||
}
|
||||
}, 'json');
|
||||
}
|
||||
|
||||
</script>
|
||||
|
||||
{template "footer.html"}
|
||||
@@ -0,0 +1,17 @@
|
||||
{search module=MOD_DIR id=$searchid total=$sototal order=$params.order catid=$catid page=1 pagesize=10 urlrule=$urlrule}
|
||||
<li class="search-item clearfix">
|
||||
<a title="{$t.title}" href="{$t.url}">
|
||||
<img src="{dr_thumb($t.thumb, 100, 90)}" width="100" height="90" style="margin-top: 15px;">
|
||||
</a>
|
||||
<div class="search-content text-left">
|
||||
<h4 class="search-title">
|
||||
<a title="{$t.title}" href="{$t.url}">{dr_strcut($t.title, 20)}</a>
|
||||
</h4>
|
||||
<p class="search-desc">{dr_strcut($t.description, 44)}</p>
|
||||
</div>
|
||||
<div class="search-post-foot">
|
||||
<a href="{dr_cat_value('news',$t.catid, 'url')}"><i class="fa fa-list"></i> {dr_cat_value(MOD_DIR,$t.catid, 'name')}</a>
|
||||
<a href="{$t.url}"><i class="fa fa-calendar"></i> {$t.updatetime}</a>
|
||||
</div>
|
||||
</li>
|
||||
{/search}
|
||||
@@ -0,0 +1,64 @@
|
||||
{template "header.html"}
|
||||
<header class="hui-header">
|
||||
<div id="hui-back"></div>
|
||||
<h1>{$title}</h1>
|
||||
<a id="hui-search" href="javascript:dr_m_top_category();"><i class="fa fa-navicon"></i></a>
|
||||
</header>
|
||||
<div class="hui-header-line"></div>
|
||||
|
||||
<div class="page-content margin-top-20">
|
||||
|
||||
|
||||
<div class="search-page search-content-2">
|
||||
<div class="portlet light">
|
||||
<div class="portlet-title">
|
||||
<div class="caption">
|
||||
<span class="caption-subject font-dark ">{$title}</span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="search-post-foot fc-content-tool">
|
||||
<div class="search-post-meta">
|
||||
<i class="fa fa-calendar font-blue"></i>
|
||||
<a href="javascript:;">{$updatetime}</a>
|
||||
</div>
|
||||
<div class="search-post-meta">
|
||||
<i class="fa fa-fire font-blue"></i>
|
||||
<a href="javascript:;">{dr_show_hits($id)}次</a>
|
||||
</div>
|
||||
</div>
|
||||
<div class="portlet-body" style="height: auto;overflow: hidden;">
|
||||
<div class="row">
|
||||
<div class="col-md-12 xrcontent">
|
||||
{dr_text_full($content)}
|
||||
</div>
|
||||
<div class="col-md-12">
|
||||
<div class="blog-single-foot fc-news-tag-list">
|
||||
<ul class="blog-post-tags">
|
||||
{loop $kws $name $url2}
|
||||
<li class="uppercase">
|
||||
<a href="{$url2}">{$name}</a>
|
||||
</li>
|
||||
{/loop}
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="blog-single-foot">
|
||||
<p class="fc-show-prev-next">
|
||||
<strong>上一篇:</strong>{if $prev_page}<a href="{$prev_page.url}">{$prev_page.title}</a>{else}没有了{/if}<br>
|
||||
</p>
|
||||
<p class="fc-show-prev-next">
|
||||
<strong>下一篇:</strong>{if $next_page}<a href="{$next_page.url}">{$next_page.title}</a>{else}没有了{/if}
|
||||
</p>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
{template "footer.html"}
|
||||
@@ -0,0 +1,94 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="zh-CN">
|
||||
<head>
|
||||
<title>{$title}</title>
|
||||
<meta content="{$title}" name="keywords" />
|
||||
<meta content="{str_replace('"', '', $description)}" name="description" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<link href="{THEME_PATH}assets/global/plugins/bootstrap/css/bootstrap.min.css" rel="stylesheet" type="text/css" />
|
||||
<script src="{THEME_PATH}assets/global/plugins/bootstrap/js/bootstrap.min.js" type="text/javascript"></script>
|
||||
</head>
|
||||
<body class="page-container-bg-solid">
|
||||
<div class="container">
|
||||
<h2>{$title}</h2>
|
||||
<p style="margin-bottom: 20px;">{dr_date($_inputtime)} <b>{$author}</b></p>
|
||||
{$content}
|
||||
</div>
|
||||
<style>
|
||||
img {width: 100%}
|
||||
h2 {
|
||||
padding-bottom: 10px;
|
||||
margin-bottom: 20px;
|
||||
border-bottom: 1px solid #e7e7eb;
|
||||
}
|
||||
</style>
|
||||
|
||||
<?php //微信分享配置; ?>
|
||||
<?php $imgUrl = $thumb ? dr_get_file($thumb) : SITE_URL.'static/banner/index1.jpg'; ?>
|
||||
<?php $title = SITE_NAME.':'. $title ; ?>
|
||||
<script src="http://res.wx.qq.com/open/js/jweixin-1.0.0.js"></script>
|
||||
<script>
|
||||
wx.config({
|
||||
debug: <?php IS_DEV ? 'true' : 'false';?>,
|
||||
appId: '<?php echo $signPackage["appId"];?>',
|
||||
timestamp: <?php echo $signPackage["timestamp"];?>,
|
||||
nonceStr: '<?php echo $signPackage["nonceStr"];?>',
|
||||
signature: '<?php echo $signPackage["signature"];?>',
|
||||
jsApiList: ['onMenuShareTimeline', 'onMenuShareQQ', 'onMenuShareQZone', 'onMenuShareAppMessage']
|
||||
});
|
||||
wx.ready(function () {
|
||||
// 在这里调用 API
|
||||
wx.onMenuShareTimeline({
|
||||
title: '{$title}', // 分享标题
|
||||
desc: '{$description}', // 分享描述
|
||||
link: '{dr_now_url()}', // 分享链接
|
||||
imgUrl: '{$imgUrl}', // 分享图标
|
||||
success: function () {
|
||||
// 用户确认分享后执行的回调函数
|
||||
},
|
||||
cancel: function () {
|
||||
// 用户取消分享后执行的回调函数
|
||||
}
|
||||
});
|
||||
wx.onMenuShareAppMessage({
|
||||
title: '{$title}', // 分享标题
|
||||
desc: '{$description}', // 分享描述
|
||||
link: '{dr_now_url()}', // 分享链接
|
||||
imgUrl: '{$imgUrl}', // 分享图标
|
||||
success: function () {
|
||||
// 用户确认分享后执行的回调函数
|
||||
},
|
||||
cancel: function () {
|
||||
// 用户取消分享后执行的回调函数
|
||||
}
|
||||
});
|
||||
wx.onMenuShareQQ({
|
||||
title: '{$title}', // 分享标题
|
||||
desc: '{$description}', // 分享描述
|
||||
link: '{dr_now_url()}', // 分享链接
|
||||
imgUrl: '{$imgUrl}', // 分享图标
|
||||
success: function () {
|
||||
// 用户确认分享后执行的回调函数
|
||||
},
|
||||
cancel: function () {
|
||||
// 用户取消分享后执行的回调函数
|
||||
}
|
||||
});
|
||||
wx.onMenuShareQZone({
|
||||
title: '{$title}', // 分享标题
|
||||
desc: '{$description}', // 分享描述
|
||||
link: '{dr_now_url()}', // 分享链接
|
||||
imgUrl: '{$imgUrl}', // 分享图标
|
||||
success: function () {
|
||||
// 用户确认分享后执行的回调函数
|
||||
},
|
||||
cancel: function () {
|
||||
// 用户取消分享后执行的回调函数
|
||||
}
|
||||
});
|
||||
|
||||
});
|
||||
</script>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user