first
This commit is contained in:
4
modules/search/README.md
Normal file
4
modules/search/README.md
Normal file
@@ -0,0 +1,4 @@
|
||||
## Copyright and license
|
||||
Copyright 2020 Redblock, Inc.
|
||||
|
||||
Licensed under the [RBL](https://kimsq.com/p/rbl) License
|
||||
30
modules/search/action/a.config.php
Normal file
30
modules/search/action/a.config.php
Normal file
@@ -0,0 +1,30 @@
|
||||
<?php
|
||||
if(!defined('__KIMS__')) exit;
|
||||
|
||||
checkAdmin(0);
|
||||
|
||||
$_tmpdfile = $g['path_var'].'site/'.$r.'/'.$m.'.var.php';
|
||||
|
||||
$fp = fopen($_tmpdfile,'w');
|
||||
fwrite($fp, "<?php\n");
|
||||
fwrite($fp, "\$d['search']['theme'] = \"".$theme."\";\n");
|
||||
fwrite($fp, "\$d['search']['m_theme'] = \"".$m_theme."\";\n");
|
||||
fwrite($fp, "\$d['search']['num1'] = \"".$num1."\";\n");
|
||||
fwrite($fp, "\$d['search']['num2'] = \"".$num2."\";\n");
|
||||
fwrite($fp, "\$d['search']['term'] = \"".$term."\";\n");
|
||||
fwrite($fp, "\$d['search']['layout'] = \"".$layout."\";\n");
|
||||
fwrite($fp, "\$d['search']['m_layout'] = \"".$m_layout."\";\n");
|
||||
fwrite($fp, "?>");
|
||||
fclose($fp);
|
||||
@chmod($_tmpdfile,0707);
|
||||
|
||||
$_tmpdfile = $g['dir_module'].'var/search.list.txt';
|
||||
|
||||
$fp = fopen($_tmpdfile,'w');
|
||||
fwrite($fp,trim(stripslashes($searchlist)));
|
||||
fclose($fp);
|
||||
@chmod($_tmpdfile,0707);
|
||||
|
||||
setrawcookie('search_config_result', rawurlencode('설정이 변경 되었습니다.|success')); // 처리여부 cookie 저장
|
||||
getLink('reload','parent.','','');
|
||||
?>
|
||||
33
modules/search/action/a.get_searchResult.php
Normal file
33
modules/search/action/a.get_searchResult.php
Normal file
@@ -0,0 +1,33 @@
|
||||
<?php
|
||||
if(!defined('__KIMS__')) exit;
|
||||
|
||||
$recnum = $_POST['recnum'];
|
||||
|
||||
require_once $g['path_core'].'function/sys.class.php';
|
||||
// include_once $g['dir_module'].'mod/_post.php';
|
||||
|
||||
$g['postVarForSite'] = $g['path_var'].'site/'.$r.'/'.$m.'.var.php';
|
||||
$svfile = file_exists($g['postVarForSite']) ? $g['postVarForSite'] : $g['dir_module'].'var/var.php';
|
||||
include_once $svfile;
|
||||
|
||||
if ($g['mobile']&&$_SESSION['pcmode']!='Y') {
|
||||
$theme = $d['post']['skin_mobile'];
|
||||
$TMPL['start']=$start;
|
||||
} else {
|
||||
$theme = $d['post']['skin_main'];
|
||||
}
|
||||
|
||||
// include_once $g['dir_module'].'themes/'.$theme.'/_var.php';
|
||||
|
||||
$mbruid = $my['uid'];
|
||||
|
||||
$result=array();
|
||||
$result['error'] = false;
|
||||
$list=$keyword.'검색결과';
|
||||
|
||||
$result['list'] = $list;
|
||||
$result['num'] = $NUM;
|
||||
|
||||
echo json_encode($result);
|
||||
exit;
|
||||
?>
|
||||
24
modules/search/action/a.order.php
Normal file
24
modules/search/action/a.order.php
Normal file
@@ -0,0 +1,24 @@
|
||||
<?php
|
||||
if(!defined('__KIMS__')) exit;
|
||||
|
||||
checkAdmin(0);
|
||||
$device = $mobile?'mobile':'desktop';
|
||||
$_ufile = $g['path_module'].$m.'/var/var.order.'.$device.'.php';
|
||||
|
||||
$fp = fopen($_ufile,'w');
|
||||
fwrite($fp, "<?php\n");
|
||||
|
||||
foreach ($searchmembers as $_key)
|
||||
{
|
||||
$_val = explode('|',$_key);
|
||||
fwrite($fp, "\$d['search_order']['".$_val[0]."'] = array('".$_val[1]."','".$_val[2]."','".$_val[3]."');\n");
|
||||
|
||||
}
|
||||
fwrite($fp, "?>");
|
||||
fclose($fp);
|
||||
@chmod($_ufile,0707);
|
||||
|
||||
if ($autoCheck) exit;
|
||||
setrawcookie('search_config_result', rawurlencode('정보가 갱신되었습니다.|success')); // 처리여부 cookie 저장
|
||||
getLink('reload','parent.',$auto?'':'','');
|
||||
?>
|
||||
20
modules/search/action/a.search_edit.php
Normal file
20
modules/search/action/a.search_edit.php
Normal file
@@ -0,0 +1,20 @@
|
||||
<?php
|
||||
if(!defined('__KIMS__')) exit;
|
||||
|
||||
checkAdmin(0);
|
||||
|
||||
if (!$namefile || strstr($namefile,'/')) exit;
|
||||
$_newsites = '';
|
||||
foreach($aply_sites as $sites) $_newsites.= '['.$sites.']';
|
||||
$_nameinfo = str_replace('|','/',trim($name)).'|'.$_newsites;
|
||||
$device = $mobile?'mobile.':'desktop.';
|
||||
$_namefile = $g['dir_module'].'var/names/'.$device.$namefile.'.txt';
|
||||
|
||||
$fp = fopen($_namefile,'w');
|
||||
fwrite($fp,$_nameinfo);
|
||||
fclose($fp);
|
||||
@chmod($_namefile,0707);
|
||||
|
||||
setrawcookie('search_config_result', rawurlencode('반영 되었습니다.|success')); // 처리여부 cookie 저장
|
||||
getLink($g['s'].'/?r='.$r.'&m=admin&module='.$m.'&searchfile='.$searchfile.'&autoCheck=Y&mobile='.$mobile,'parent.','','');
|
||||
?>
|
||||
4
modules/search/admin.php
Normal file
4
modules/search/admin.php
Normal file
@@ -0,0 +1,4 @@
|
||||
<?php
|
||||
if(!defined('__KIMS__')) exit;
|
||||
include $g['path_module'].$module.'/admin/'.$front.'.php';
|
||||
?>
|
||||
29
modules/search/admin/_info.php
Normal file
29
modules/search/admin/_info.php
Normal file
@@ -0,0 +1,29 @@
|
||||
<?php
|
||||
$license_local = $g['path_module'].$module.'/LICENSE';
|
||||
$license_global = $g['path_root'].'LICENSE';
|
||||
|
||||
if (file_exists($license_local)) $license = $license_local;
|
||||
else $license = $license_global;
|
||||
?>
|
||||
|
||||
<link href="<?php echo $g['s']?>/_core/css/github-markdown.css" rel="stylesheet">
|
||||
<?php getImport('jquery-markdown','jquery.markdown','0.0.10','js')?>
|
||||
|
||||
<?php @include $g['path_module'].$module.'/var/var.moduleinfo.php' ?>
|
||||
|
||||
<article class="rb-docs markdown-body px-5 pt-3">
|
||||
<h1><?php echo sprintf('%s 모듈정보',ucfirst($MD['name']))?></h1>
|
||||
|
||||
<div class="pb-5 readme">
|
||||
<?php readfile($g['path_module'].$module.'/README.md')?>
|
||||
</div>
|
||||
|
||||
<div class="pb-5">
|
||||
<h2>라이센스</h2>
|
||||
<textarea class="form-control" rows="10"><?php readfile($license)?></textarea>
|
||||
</div>
|
||||
</article>
|
||||
|
||||
<script type="text/javascript">
|
||||
$(".markdown-body .readme").markdown();
|
||||
</script>
|
||||
405
modules/search/admin/main.css
Normal file
405
modules/search/admin/main.css
Normal file
@@ -0,0 +1,405 @@
|
||||
#search-body .panel-body {
|
||||
padding: 0 10px 15px;
|
||||
border-top: 1px dotted #c0c0c0
|
||||
}
|
||||
|
||||
#search-body .panel-body.rb-panel-form {
|
||||
border-top: none;
|
||||
}
|
||||
|
||||
#search-body .panel-body.rb-panel-form select {
|
||||
background-color: #f5f5f5
|
||||
}
|
||||
|
||||
#search-body .rb-eye-close {
|
||||
color: #c0c0c0;
|
||||
}
|
||||
|
||||
#search-body .rb-top-btnbox {
|
||||
position: relative;
|
||||
top: -10px;
|
||||
}
|
||||
|
||||
#accordion>.card .card-body {
|
||||
height: calc(100vh - 12rem);
|
||||
overflow: auto;
|
||||
}
|
||||
|
||||
/**
|
||||
* Nestable
|
||||
*/
|
||||
|
||||
.dd {
|
||||
position: relative;
|
||||
display: block;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
list-style: none;
|
||||
line-height: 20px
|
||||
}
|
||||
|
||||
.dd-list {
|
||||
display: block;
|
||||
position: relative;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
list-style: none
|
||||
}
|
||||
|
||||
.dd-item,
|
||||
.dd-empty,
|
||||
.dd-placeholder {
|
||||
display: block;
|
||||
position: relative;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
min-height: 20px;
|
||||
line-height: 20px
|
||||
}
|
||||
|
||||
.dd-handle {
|
||||
display: block;
|
||||
height: 35px;
|
||||
margin: 5px 0;
|
||||
padding: 5px 10px;
|
||||
color: #333;
|
||||
text-decoration: none;
|
||||
font-weight: bold;
|
||||
border: 1px solid #ddd;
|
||||
background: #fafafa;
|
||||
background: -webkit-linear-gradient(top, #fafafa 0%, #eee 100%);
|
||||
background: -moz-linear-gradient(top, #fafafa 0%, #eee 100%);
|
||||
background: linear-gradient(top, #fafafa 0%, #eee 100%);
|
||||
-webkit-border-radius: 3px;
|
||||
border-radius: 3px;
|
||||
box-sizing: border-box;
|
||||
-moz-box-sizing: border-box;
|
||||
}
|
||||
|
||||
.dd-handle:hover {
|
||||
color: #2ea8e5;
|
||||
background: #fff;
|
||||
}
|
||||
|
||||
|
||||
.dd-placeholder,
|
||||
.dd-empty {
|
||||
margin: 5px 0;
|
||||
padding: 0;
|
||||
min-height: 30px;
|
||||
background: #f2fbff;
|
||||
border: 1px dashed #b6bcbf;
|
||||
box-sizing: border-box;
|
||||
-moz-box-sizing: border-box
|
||||
}
|
||||
|
||||
.dd-empty {
|
||||
border: 1px dashed #bbb;
|
||||
min-height: 100px;
|
||||
background-color: #e5e5e5;
|
||||
background-image: -webkit-linear-gradient(45deg, #fff 25%, transparent 25%, transparent 75%, #fff 75%, #fff),
|
||||
-webkit-linear-gradient(45deg, #fff 25%, transparent 25%, transparent 75%, #fff 75%, #fff);
|
||||
background-image: -moz-linear-gradient(45deg, #fff 25%, transparent 25%, transparent 75%, #fff 75%, #fff),
|
||||
-moz-linear-gradient(45deg, #fff 25%, transparent 25%, transparent 75%, #fff 75%, #fff);
|
||||
background-image: linear-gradient(45deg, #fff 25%, transparent 25%, transparent 75%, #fff 75%, #fff),
|
||||
linear-gradient(45deg, #fff 25%, transparent 25%, transparent 75%, #fff 75%, #fff);
|
||||
background-size: 60px 60px;
|
||||
background-position: 0 0, 30px 30px;
|
||||
}
|
||||
|
||||
.dd-dragel {
|
||||
position: absolute;
|
||||
pointer-events: none;
|
||||
z-index: 9999
|
||||
}
|
||||
|
||||
.dd-dragel>.dd-item .dd-handle {
|
||||
margin-top: 0
|
||||
}
|
||||
|
||||
.dd-dragel .dd-handle {
|
||||
-webkit-box-shadow: 2px 4px 6px 0 rgba(0, 0, 0, .1);
|
||||
box-shadow: 2px 4px 6px 0 rgba(0, 0, 0, .1)
|
||||
}
|
||||
|
||||
/**
|
||||
* Nestable Extras
|
||||
*/
|
||||
|
||||
|
||||
#nestable-menu {
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
#nestable-output,
|
||||
|
||||
@media only screen and (min-width: 700px) {
|
||||
|
||||
.dd {
|
||||
float: left;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.dd+.dd {
|
||||
margin-left: 2%;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
.dd-hover>.dd-handle {
|
||||
background: #2ea8e5 !important;
|
||||
}
|
||||
|
||||
/**
|
||||
* Nestable Draggable Handles
|
||||
*/
|
||||
|
||||
.dd3-content {
|
||||
display: block;
|
||||
height: 35px;
|
||||
margin: 5px 0;
|
||||
line-height: 20px;
|
||||
padding: 6px 10px 4px 40px;
|
||||
color: #333;
|
||||
border: 1px solid #ddd;
|
||||
background: #eee;
|
||||
-webkit-border-radius: 3px;
|
||||
border-radius: 3px;
|
||||
box-sizing: border-box;
|
||||
-moz-box-sizing: border-box;
|
||||
}
|
||||
|
||||
#collapseOne .dd-item .dd3-content a {
|
||||
display: block;
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
.dd3-content:hover {
|
||||
background: #f5f5f5
|
||||
}
|
||||
|
||||
.dd3-content small {
|
||||
color: #999
|
||||
}
|
||||
|
||||
.dd-item.rb-active .dd3-content {
|
||||
background-color: #428bca;
|
||||
border-color: #357ebd;
|
||||
color: #fff
|
||||
}
|
||||
|
||||
.dd-item.rb-active .dd3-content a,
|
||||
.dd-item.rb-active .dd3-content small {
|
||||
color: #fff
|
||||
}
|
||||
|
||||
.dd-dragel>.dd3-item>.dd3-content {
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.dd3-item>button {
|
||||
margin-left: 30px;
|
||||
}
|
||||
|
||||
.dd3-handle {
|
||||
position: absolute;
|
||||
margin: 0;
|
||||
left: 0;
|
||||
top: 0;
|
||||
cursor: pointer;
|
||||
width: 30px;
|
||||
text-indent: 100%;
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
border: 1px solid #ddd;
|
||||
background: #ddd;
|
||||
|
||||
border-top-right-radius: 0;
|
||||
border-bottom-right-radius: 0;
|
||||
cursor: move
|
||||
}
|
||||
|
||||
.dd-checkbox {
|
||||
line-height: 28px;
|
||||
position: absolute;
|
||||
margin: 0;
|
||||
right: 0;
|
||||
top: 0;
|
||||
width: 30px;
|
||||
padding: 5px 20px 10px 5px
|
||||
}
|
||||
|
||||
.dd3-handle:before {
|
||||
font-family: 'FontAwesome';
|
||||
content: '\f047';
|
||||
display: block;
|
||||
position: absolute;
|
||||
left: 5px;
|
||||
top: 6px;
|
||||
text-align: center;
|
||||
text-indent: 0;
|
||||
color: #888;
|
||||
font-size: 18px;
|
||||
font-weight: normal
|
||||
}
|
||||
|
||||
.dd3-handle:hover {
|
||||
background: #ddd
|
||||
}
|
||||
|
||||
.dd3-handle-none:before {
|
||||
font-family: 'FontAwesome';
|
||||
content: '';
|
||||
cursor: none;
|
||||
display: block;
|
||||
position: absolute;
|
||||
left: 5px;
|
||||
top: 6px;
|
||||
text-align: center;
|
||||
text-indent: 0;
|
||||
color: #888;
|
||||
font-size: 18px;
|
||||
font-weight: normal
|
||||
}
|
||||
|
||||
.dd3-handle-none:hover {
|
||||
background: #ddd;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.panel-footer ul.list-inline {
|
||||
margin-bottom: 0
|
||||
}
|
||||
|
||||
|
||||
#search-body .rb-none {
|
||||
line-height: 400px;
|
||||
text-align: center;
|
||||
color: #999
|
||||
}
|
||||
|
||||
|
||||
#search-body .rb-main .page-header {
|
||||
margin-top: 35px
|
||||
}
|
||||
|
||||
#search-body .rb-main .page-header:first-child {
|
||||
margin-top: 0
|
||||
}
|
||||
|
||||
|
||||
#search-body .rb-main .checkbox-inline.rb-no-indent,
|
||||
#search-body .rb-main .checkbox-inline.rb-no-indent+.checkbox-inline.rb-no-indent {
|
||||
margin-left: 0;
|
||||
margin-right: 15px;
|
||||
}
|
||||
|
||||
#search-body .rb-main .checkbox.inline.no_indent:last-child {
|
||||
margin-right: 0px;
|
||||
}
|
||||
|
||||
|
||||
#search-body .rb-files {
|
||||
padding: 2px;
|
||||
background: #eee;
|
||||
border-radius: 3px;
|
||||
margin-top: 35px;
|
||||
}
|
||||
|
||||
#search-body .rb-codeview {
|
||||
border-radius: 3px;
|
||||
border: 1px solid #c9c9c9;
|
||||
-webkit-box-shadow: inset 1px 1px 0px 0px rgba(222, 2222, 222, 0.1), 1px 1px 0px 0px rgba(255, 255, 255, 1);
|
||||
box-shadow: inset 1px 1px 0px 0px rgba(222, 222, 222, 0.1), 1px 1px 0px 0px rgba(255, 255, 255, 1);
|
||||
}
|
||||
|
||||
#search-body .rb-codeview-header,
|
||||
#search-body .rb-codeview-footer {
|
||||
font: 12px "Helvetica Neue", Helvetica, arial, freesans, clean, sans-serif;
|
||||
text-shadow: 1px 1px rgba(255, 255, 255, 0.8);
|
||||
overflow: hidden;
|
||||
color: #999;
|
||||
}
|
||||
|
||||
#search-body .rb-codeview-header .breadcrumb {
|
||||
background-color: transparent;
|
||||
margin-bottom: 0;
|
||||
padding: 0;
|
||||
line-height: 30px
|
||||
}
|
||||
|
||||
#search-body .rb-codeview-header .btn {
|
||||
line-height: 20px;
|
||||
margin-top: 4px;
|
||||
border-radius: 3px
|
||||
}
|
||||
|
||||
#search-body .rb-codeview-header {
|
||||
border-bottom: 1px solid #ddd;
|
||||
padding: 5px 10px;
|
||||
text-shadow: 0 1px 0 #fff;
|
||||
border-bottom: 1px solid #d8d8d8;
|
||||
background-color: #eaeaea;
|
||||
background-image: -moz-linear-gradient(#fafafa, #eaeaea);
|
||||
background-image: -webkit-linear-gradient(#fafafa, #eaeaea);
|
||||
background-image: linear-gradient(#fafafa, #eaeaea);
|
||||
background-repeat: repeat-x;
|
||||
}
|
||||
|
||||
#search-body .rb-codeview-body {
|
||||
font-family: Consolas, "Liberation Mono", Courier, monospace;
|
||||
}
|
||||
|
||||
#search-body .rb-codeview-body textarea {
|
||||
overflow: auto;
|
||||
border: none;
|
||||
padding: 15px;
|
||||
line-height: 150%;
|
||||
background: #000000;
|
||||
color: #ffffff;
|
||||
font-size: 12px;
|
||||
border-radius: 0
|
||||
}
|
||||
|
||||
#search-body .rb-codeview-footer {
|
||||
border-top: 1px solid #ddd;
|
||||
padding: 10px;
|
||||
background-color: #e8e8e8;
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#fafafa), to(#e8e8e8));
|
||||
background-image: -webkit-linear-gradient(#fafafa, #e8e8e8);
|
||||
background-image: linear-gradient(#fafafa, #e8e8e8);
|
||||
background-repeat: repeat-x;
|
||||
}
|
||||
|
||||
#search-body .rb-codeview-footer ul {
|
||||
margin-bottom: 0
|
||||
}
|
||||
|
||||
#search-body .rb-codeview-footer li:first-child,
|
||||
#search-body .rb-codeview-footer li:last-child {
|
||||
border-left: 0;
|
||||
box-shadow: inset 0 0 0 transparent;
|
||||
padding-left: 0;
|
||||
margin-left: 0;
|
||||
}
|
||||
|
||||
#search-body .rb-codeview-footer li {
|
||||
display: inline-block;
|
||||
color: #555555;
|
||||
padding-left: 9px;
|
||||
margin-left: 5px;
|
||||
border-left: 1px solid #c1c1c1;
|
||||
box-shadow: inset 1px 0 0 #fff;
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
#search-body .rb-submit {
|
||||
margin: 15px 0
|
||||
}
|
||||
|
||||
@media (max-width: 767px) {
|
||||
.rb-guide {
|
||||
padding-left: 20px;
|
||||
}
|
||||
}
|
||||
532
modules/search/admin/main.php
Normal file
532
modules/search/admin/main.php
Normal file
@@ -0,0 +1,532 @@
|
||||
<?php
|
||||
function getSearchFileList($folder)
|
||||
{
|
||||
$incs = array();
|
||||
$dirh = opendir($folder);
|
||||
while(false !== ($files = readdir($dirh)))
|
||||
{
|
||||
if(substr($files,-4)!='.php') continue;
|
||||
$incs[] = str_replace('.php','',$files);
|
||||
}
|
||||
closedir($dirh);
|
||||
return $incs;
|
||||
}
|
||||
|
||||
$g['searchVarForSite'] = $g['path_var'].'site/'.$r.'/search.var.php';
|
||||
$_tmpdfile = file_exists($g['searchVarForSite']) ? $g['searchVarForSite'] : $g['path_module'].$module.'/var/var.search.php';
|
||||
include_once $_tmpdfile;
|
||||
|
||||
$device = $mobile?'mobile':'desktop';
|
||||
include_once $g['path_module'].$module.'/var/var.order.'.$device.'.php';
|
||||
|
||||
$MODULE_LIST = getDbArray($table['s_module'],'','*','gid','asc',0,$p);
|
||||
$_names = array();
|
||||
$PAGESET = array();
|
||||
$TMPST = array();
|
||||
$SITES = getDbArray($table['s_site'],'','*','gid','asc',0,$p);
|
||||
$SITEN = db_num_rows($SITES);
|
||||
?>
|
||||
|
||||
<div class="row no-gutters" id="search-body">
|
||||
<div class="col-sm-4 col-md-4 col-xl-3 d-none d-sm-block sidebar">
|
||||
|
||||
<div class="border border-primary">
|
||||
<select class="form-control custom-select border-0" name="device" onchange="goHref('<?php echo $g['s']?>/?m=<?php echo $m?>&module=<?php echo $module?>&front=<?php echo $front?>&autoCheck=Y&searchfile=<?php echo $searchfile?>&r=<?php echo $r?>&mobile='+this.value);">
|
||||
<option value=""<?php if(!$mobile):?> selected<?php endif?>>데스크탑</option>
|
||||
<option value="1"<?php if($mobile):?> selected<?php endif?>>모바일</option>
|
||||
</select>
|
||||
</div>
|
||||
|
||||
<div class="panel-group" id="accordion">
|
||||
<div class="card">
|
||||
<div class="card-header p-0">
|
||||
<a class="accordion-toggle muted-link d-block<?php if($_SESSION['search_main_collapse']):?> collapsed<?php endif?>"
|
||||
data-toggle="collapse" href="#collapseOne"
|
||||
onclick="sessionSetting('search_main_collapse','','','');">
|
||||
<i class="fa fa-search fa-lg fa-fw"></i>
|
||||
통합검색 지원모듈
|
||||
</a>
|
||||
</div>
|
||||
|
||||
<div class="panel-collapse collapse<?php if(!$_SESSION['search_main_collapse']):?> show<?php endif?>" id="collapseOne" data-parent="#accordion">
|
||||
<div class="card-body">
|
||||
<?php $_i=0;while($MD = db_fetch_array($MODULE_LIST)):?>
|
||||
<?php
|
||||
if ($mobile){
|
||||
$forsearching_folder=$g['path_module'].$MD['id'].'/for-searching/_mobile';
|
||||
}else{
|
||||
$forsearching_folder=$g['path_module'].$MD['id'].'/for-searching/_desktop';
|
||||
}
|
||||
?>
|
||||
<?php if(!is_dir($forsearching_folder)) continue?>
|
||||
<div class="mt-2 py-1">
|
||||
<h6 class="mb-0">
|
||||
<small class="text-muted"><i class="<?php echo $MD['icon']?>"></i> <?php echo $MD['name']?> (<?php echo $MD['id']?>)</small>
|
||||
</h6>
|
||||
<div class="dd">
|
||||
<ol class="dd-list">
|
||||
<?php foreach(getSearchFileList($forsearching_folder) as $_file):?>
|
||||
<?php $device = $mobile?'mobile.':'desktop.' ?>
|
||||
<?php $_namefile = $g['path_module'].$module.'/var/names/'.$device.$MD['id'].'-'.$_file.'.txt'?>
|
||||
<?php $_names = is_file($_namefile) ? explode('|',implode('',file($_namefile))):array()?>
|
||||
<?php $PAGESET[$MD['id'].'_'.$_file] = array('filename'=>$_file,'filerename'=>$_names[0]?$_names[0]:$_file,'moduleid'=>$MD['id'],'modulename'=>$MD['name'],'site'=>$_names[1],'filepath'=>$forsearching_folder.'/'.$_file)?>
|
||||
<li class="dd-item dd3-item<?php if($MD['id'].'/'.$_file==$searchfile):?> rb-active<?php endif?>">
|
||||
<div class="dd-handle dd3-handle dd3-handle-none"></div>
|
||||
<div class="dd3-content">
|
||||
<i class="fa fa-file" style="position:absolute;left:10px;top:10px;color:#000;"></i>
|
||||
<a href="<?php echo $g['adm_href']?>&searchfile=<?php echo $MD['id'].'/'.$_file?>&mobile=<?php echo $mobile?>"><?php echo $_file?>.php</a>
|
||||
</div>
|
||||
</li>
|
||||
<?php endforeach?>
|
||||
</ol>
|
||||
</div>
|
||||
</div>
|
||||
<?php $_i++;endwhile?>
|
||||
<?php if(!$_i):?>
|
||||
<div class="card-body rb-none">
|
||||
통합검색 지원모듈이 없습니다.
|
||||
</div>
|
||||
<?php endif?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="card">
|
||||
<div class="card-header p-0">
|
||||
<a class="accordion-toggle muted-link d-block<?php if(!$_SESSION['search_main_collapse']):?> collapsed<?php endif?>" data-toggle="collapse" href="#collapseTwo" onclick="sessionSetting('search_main_collapse','order','','');">
|
||||
<i class="fa fa-retweet fa-lg fa-fw"></i>
|
||||
출력옵션 및 순서조정
|
||||
</a>
|
||||
</div>
|
||||
<div class="panel-collapse collapse<?php if($_SESSION['search_main_collapse']):?> show<?php endif?>" id="collapseTwo" data-parent="#accordion">
|
||||
<form role="form" action="<?php echo $g['s']?>/" method="post">
|
||||
<input type="hidden" name="r" value="<?php echo $r?>">
|
||||
<input type="hidden" name="m" value="<?php echo $module?>">
|
||||
<input type="hidden" name="a" value="order">
|
||||
<input type="hidden" name="mobile" value="<?php echo $mobile?>">
|
||||
<input type="hidden" name="auto" value="">
|
||||
<input type="hidden" name="autoCheck" value="<?php echo $autoCheck ?>">
|
||||
<div class="card-body">
|
||||
<div class="dd" id="nestable-menu">
|
||||
<ol class="dd-list">
|
||||
<?php $_i=0;if(count($d['search_order'])):foreach($d['search_order'] as $_key => $_val):?>
|
||||
<?php if(!is_array($PAGESET[$_key]))continue?>
|
||||
<li class="dd-item dd3-item<?php if($PAGESET[$_key]['moduleid'].'/'.$PAGESET[$_key]['filename']==$searchfile):?> rb-active<?php endif?>" data-id="<?php echo $_i?>">
|
||||
<div class="dd-handle dd3-handle"></div>
|
||||
<div class="dd3-content"><a href="<?php echo $g['adm_href']?>&searchfile=<?php echo $PAGESET[$_key]['moduleid'].'/'.$PAGESET[$_key]['filename']?>&mobile=<?php echo $mobile?>" title="<?php echo $PAGESET[$_key]['filename']?>.php" data-tooltip="tooltip"><?php echo $PAGESET[$_key]['filerename']?></a> <small title="<?php echo $PAGESET[$_key]['modulename']?>" data-tooltip="tooltip">(<?php echo $PAGESET[$_key]['moduleid']?>)</small></div>
|
||||
<div class="dd-checkbox">
|
||||
<input type="checkbox" name="searchmembers[]" value="<?php echo $PAGESET[$_key]['moduleid']?>_<?php echo $PAGESET[$_key]['filename']?>|<?php echo $PAGESET[$_key]['filerename']?>|<?php echo $PAGESET[$_key]['site']?>|<?php echo $PAGESET[$_key]['filepath']?>" checked class="d-none"><i class="fa fa-eye-<?php echo strstr($PAGESET[$_key]['site'],'['.$r.']')?'open':'close rb-eye-close'?>"></i>
|
||||
</div>
|
||||
</li>
|
||||
<?php $_i++;endforeach;$_nowOrderNum=$_i;endif?>
|
||||
<?php foreach($PAGESET as $_key => $_val):?>
|
||||
<?php if(is_array($d['search_order'][$_key]))continue?>
|
||||
<li class="dd-item dd3-item<?php if($_val['moduleid'].'/'.$_val['filename']==$searchfile):?> rb-active<?php endif?>" data-id="<?php echo $_i?>">
|
||||
<div class="dd-handle dd3-handle"></div>
|
||||
<div class="dd3-content"><a href="<?php echo $g['adm_href']?>&searchfile=<?php echo $_val['moduleid'].'/'.$_val['filename']?>&mobile=<?php echo $mobile?>" title="<?php echo $_val['filename']?>.php" data-tooltip="tooltip"><?php echo $_val['filerename']?></a> <small title="<?php echo $_val['modulename']?>" data-tooltip="tooltip">(<?php echo $_val['moduleid']?>)</small></div>
|
||||
<div class="dd-checkbox">
|
||||
<input type="checkbox" name="searchmembers[]" value="<?php echo $_val['moduleid']?>_<?php echo $_val['filename']?>|<?php echo $_val['filerename']?>|<?php echo $_val['site']?>|<?php echo $_val['filepath']?>" checked class="hidden"><i class="fa fa-eye-<?php echo strstr($_val['site'],'['.$r.']')?'open':'close rb-eye-close'?>"></i>
|
||||
</div>
|
||||
</li>
|
||||
<?php $_i++;endforeach;$_nowOrderNum=$_i?>
|
||||
</ol>
|
||||
</div>
|
||||
</div>
|
||||
<?php if(!$_i):?>
|
||||
<div class="card-body rb-none">
|
||||
등록된 검색페이지가 없습니다.
|
||||
</div>
|
||||
<?php endif?>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-sm-8 col-md-8 ml-sm-auto col-xl-9">
|
||||
|
||||
<?php
|
||||
if($searchfile):
|
||||
$_searchfl = str_replace('/','-',$searchfile);
|
||||
$device = $mobile?'mobile.':'desktop.';
|
||||
$_namefile = $g['path_module'].$module.'/var/names/'.$device.$_searchfl.'.txt';
|
||||
|
||||
if (is_file($_namefile)) $_names = explode('|',implode('',file($_namefile)));
|
||||
else $_names = array();
|
||||
?>
|
||||
|
||||
<form name="procForm" role="form" action="<?php echo $g['s']?>/" method="post" onsubmit="return procCheck(this);" class="card rounded-0 border-0">
|
||||
<input type="hidden" name="r" value="<?php echo $r?>">
|
||||
<input type="hidden" name="m" value="<?php echo $module?>">
|
||||
<input type="hidden" name="a" value="search_edit">
|
||||
<input type="hidden" name="mobile" value="<?php echo $mobile?>">
|
||||
<input type="hidden" name="namefile" value="<?php echo $_searchfl?>">
|
||||
<input type="hidden" name="searchfile" value="<?php echo $searchfile?>">
|
||||
|
||||
|
||||
<div class="card-header d-flex justify-content-between align-items-center py-1">
|
||||
등록정보 및 사이트 지정
|
||||
<div class="">
|
||||
<a href="<?php echo $g['adm_href']?>" class="btn btn-light"><i class="fa fa-cog"></i> 통합검색 설정</a>
|
||||
<div class="btn-group rb-btn-view">
|
||||
<a href="<?php echo $g['s']?>/?r=<?php echo $r?>&m=<?php echo $module?>" class="btn btn-light">접속하기</a>
|
||||
<button type="button" class="btn btn-light dropdown-toggle dropdown-toggle-split" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
|
||||
<span class="sr-only">Toggle Dropdown</span>
|
||||
</button>
|
||||
<div class="dropdown-menu dropdown-menu-right" role="menu">
|
||||
<a class="dropdown-item" href="<?php echo $g['s']?>/?r=<?php echo $r?>&m=<?php echo $module?>" target="_blank">
|
||||
<i class="fa fa-external-link"></i> 새창으로 보기
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div><!-- /.card-header -->
|
||||
|
||||
<div class="card-body">
|
||||
<div class="form-group row">
|
||||
<label class="col-lg-2 col-form-label text-lg-right">검색명칭</label>
|
||||
<div class="col-lg-10 col-xl-9">
|
||||
<input type="text" name="name" value="<?php echo $_names[0]?$_names[0]:$_searchfl?>" class="form-control">
|
||||
<p class="form-text text-muted">
|
||||
<small>이 파일의 검색페이지 명칭을 적절한 용어로 지정해 주세요.</small>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group row">
|
||||
|
||||
<?php while($S = db_fetch_array($SITES)):$TMPST[]=array($S['name'],$S['id'])?><?php endwhile?>
|
||||
|
||||
<label class="col-lg-2 col-form-label text-lg-right">출력사이트</label>
|
||||
<div class="col-lg-10 col-xl-9 pt-1">
|
||||
<?php foreach($TMPST as $_val):?>
|
||||
<div class="custom-control custom-checkbox custom-control-inline">
|
||||
<input type="checkbox" class="custom-control-input" id="aply_sites_<?php echo $_val[1]?>" name="aply_sites[]" value="<?php echo $_val[1]?>"<?php if(strstr($_names[1],'['.$_val[1].']')):?> checked<?php endif?>>
|
||||
<label class="custom-control-label" for="aply_sites_<?php echo $_val[1]?>"><?php echo $_val[0]?> <small class="text-muted">(<?php echo $_val[1]?>)</small></label>
|
||||
</div>
|
||||
<?php endforeach?>
|
||||
</div>
|
||||
</div>
|
||||
<hr>
|
||||
<div class="row">
|
||||
<div class="col-lg-10 offset-lg-2 col-xl-9 offset-xl-2 clearfix">
|
||||
<div class="btn-group">
|
||||
<button type="button" class="btn btn-light" onclick="checkboxChoice('aply_sites[]',true);">전체선택</button>
|
||||
<button type="button" class="btn btn-light" onclick="checkboxChoice('aply_sites[]',false);">전체취소</button>
|
||||
</div>
|
||||
<button class="btn btn-primary ml-3" type="submit" id="rb-submit-button"><i class="fa fa-check fa-lg"></i> 저장하기</button>
|
||||
</div>
|
||||
</div>
|
||||
</div><!-- /.card-body -->
|
||||
</form><!-- /.card -->
|
||||
|
||||
|
||||
<?php else:?>
|
||||
<form name="saveForm" role="form" action="<?php echo $g['s']?>/" method="post" onsubmit="return saveCheck(this);" class="card rounded-0 border-0">
|
||||
<input type="hidden" name="r" value="<?php echo $r?>">
|
||||
<input type="hidden" name="m" value="<?php echo $module?>">
|
||||
<input type="hidden" name="a" value="config">
|
||||
<input type="hidden" name="layout" value="">
|
||||
<input type="hidden" name="m_layout" value="">
|
||||
|
||||
<div class="card-header d-flex justify-content-between align-items-center py-1">
|
||||
검색범위
|
||||
<div class="">
|
||||
<div class="btn-group rb-btn-view">
|
||||
<a href="<?php echo $g['s']?>/?r=<?php echo $r?>&m=<?php echo $module?>" class="btn btn-light">전체</a>
|
||||
<button type="button" class="btn btn-light dropdown-toggle dropdown-toggle-split" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
|
||||
<span class="sr-only">Toggle Dropdown</span>
|
||||
</button>
|
||||
<div class="dropdown-menu dropdown-menu-right" role="menu">
|
||||
<a class="dropdown-item" href="<?php echo $g['s']?>/?r=<?php echo $r?>&m=<?php echo $module?>" target="_blank">
|
||||
<i class="fa fa-external-link"></i> 최근 3년
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div><!-- /.card-header -->
|
||||
|
||||
<div class="card-body">
|
||||
<div class="form-group row">
|
||||
<label class="col-lg-2 col-form-label text-lg-right">검색테마</label>
|
||||
<div class="col-lg-10 col-xl-9">
|
||||
<select class="form-control custom-select" name="theme">
|
||||
<optgroup label="데스크탑">
|
||||
<?php $dirs = opendir($g['path_module'].$module.'/themes/_desktop')?>
|
||||
<?php while(false !== ($theme = readdir($dirs))):?>
|
||||
<?php if(strpos('_..',$theme))continue?>
|
||||
<option value="_desktop/<?php echo $theme?>"<?php if($d['search']['theme']=='_desktop/'.$theme):?> selected<?php endif?>><?php echo $theme?></option>
|
||||
<?php endwhile?>
|
||||
<?php closedir($dirs)?>
|
||||
</optgroup>
|
||||
<optgroup label="모바일">
|
||||
<?php $dirs = opendir($g['path_module'].$module.'/themes/_mobile')?>
|
||||
<?php while(false !== ($theme = readdir($dirs))):?>
|
||||
<?php if(strpos('_..',$theme))continue?>
|
||||
<option value="_mobile/<?php echo $theme?>"<?php if($d['search']['theme']=='_mobile/'.$theme):?> selected<?php endif?>><?php echo $theme?></option>
|
||||
<?php endwhile?>
|
||||
<?php closedir($dirs)?>
|
||||
</optgroup>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group row">
|
||||
<label class="col-lg-2 col-form-label text-lg-right">
|
||||
<span class="badge badge-dark">모바일</span>
|
||||
</label>
|
||||
<div class="col-lg-10 col-xl-9">
|
||||
<select class="form-control custom-select" name="m_theme">
|
||||
<optgroup label="데스크탑">
|
||||
<?php $dirs = opendir($g['path_module'].$module.'/themes/_desktop')?>
|
||||
<?php while(false !== ($theme = readdir($dirs))):?>
|
||||
<?php if(strpos('_..',$theme))continue?>
|
||||
<option value="_desktop/<?php echo $theme?>"<?php if($d['search']['m_theme']=='_desktop/'.$theme):?> selected<?php endif?>><?php echo $theme?></option>
|
||||
<?php endwhile?>
|
||||
<?php closedir($dirs)?>
|
||||
</optgroup>
|
||||
<optgroup label="모바일">
|
||||
<?php $dirs = opendir($g['path_module'].$module.'/themes/_mobile')?>
|
||||
<?php while(false !== ($theme = readdir($dirs))):?>
|
||||
<?php if(strpos('_..',$theme))continue?>
|
||||
<option value="_mobile/<?php echo $theme?>"<?php if($d['search']['m_theme']=='_mobile/'.$theme):?> selected<?php endif?>><?php echo $theme?></option>
|
||||
<?php endwhile?>
|
||||
<?php closedir($dirs)?>
|
||||
</optgroup>
|
||||
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group row">
|
||||
<label class="col-lg-2 col-form-label text-lg-right">검색범위</label>
|
||||
<div class="col-lg-10 col-xl-9">
|
||||
<select name="term" class="form-control custom-select">
|
||||
<option value="360"<?php if($d['search']['term']==360):?> selected="selected"<?php endif?>>전체</option>
|
||||
<option value="36"<?php if($d['search']['term']==36):?> selected="selected"<?php endif?>>최근 3년</option>
|
||||
<option value="24"<?php if($d['search']['term']==24):?> selected="selected"<?php endif?>>최근 2년</option>
|
||||
<option value="12"<?php if($d['search']['term']==12):?> selected="selected"<?php endif?>>최근 1년</option>
|
||||
<option value="6"<?php if($d['search']['term']==6):?> selected="selected"<?php endif?>>최근 6개월</option>
|
||||
<option value="3"<?php if($d['search']['term']==3):?> selected="selected"<?php endif?>>최근 3개월</option>
|
||||
<option value="1"<?php if($d['search']['term']==1):?> selected="selected"<?php endif?>>최근 한달</option>
|
||||
</select>
|
||||
<p class="form-text text-muted">
|
||||
<small>검색양에 따라 처리속도가 느려질 수 있습니다. 적절한 기간을 지정해 주세요.</small>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group row">
|
||||
<label class="col-lg-2 col-form-label text-lg-right">검색 결과수</label>
|
||||
<div class="col-lg-10 col-xl-9">
|
||||
|
||||
<div class="input-group" style="width:250px">
|
||||
<div class="input-group-prepend">
|
||||
<span class="input-group-text">통합검색시</span>
|
||||
</div>
|
||||
<input type="text" name="num1" size="5" value="<?php echo $d['search']['num1']?>" class="form-control text-center">
|
||||
<div class="input-group-append">
|
||||
<span class="input-group-text">개</span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="input-group" style="width:250px;margin-top:10px">
|
||||
<div class="input-group-prepend">
|
||||
<span class="input-group-text">세부검색시</span>
|
||||
</div>
|
||||
<input type="text" name="num2" size="5" value="<?php echo $d['search']['num2']?>" class="form-control text-center">
|
||||
<div class="input-group-append">
|
||||
<span class="input-group-text">개</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group row">
|
||||
<label class="col-lg-2 col-form-label text-lg-right">레이아웃</label>
|
||||
<div class="col-lg-10 col-xl-9">
|
||||
|
||||
<div class="form-row">
|
||||
<?php $_layoutExp1=explode('/',$d['search']['layout'])?>
|
||||
<?php if (!is_dir($g['path_layout'].$_layoutExp1[0])): ?>
|
||||
<div class="col-sm-12">
|
||||
<div class="alert alert-danger">
|
||||
지정된 <?php echo $g['path_layout'].$_layoutExp1[0] ?> 레이아웃이 존재하지 않습니다. 변경해 주세요.
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-sm-6" id="rb-layout-select">
|
||||
<select class="form-control custom-select" name="layout_1" required onchange="getSubLayout(this,'rb-layout-select2','layout_1_sub','custom-select');" style="letter-spacing: -1px;">
|
||||
<?php $dirs = opendir($g['path_layout'])?>
|
||||
<?php $_i=0;while(false !== ($tpl = readdir($dirs))):?>
|
||||
<?php if($tpl=='.' || $tpl == '..' || $tpl == '_blank' || is_file($g['path_layout'].$tpl))continue?>
|
||||
<option value="<?php echo $tpl?>"><?php echo getFolderName($g['path_layout'].$tpl)?>(<?php echo $tpl?>)</option>
|
||||
<?php $_i++;endwhile?>
|
||||
<?php closedir($dirs)?>
|
||||
</select>
|
||||
</div>
|
||||
<div class="col-sm-6" id="rb-layout-select2">
|
||||
<select class="form-control custom-select" name="layout_1_sub">
|
||||
</select>
|
||||
</div>
|
||||
<?php else: ?>
|
||||
<div class="col-sm-6" id="rb-layout-select">
|
||||
<select class="form-control custom-select" name="layout_1" required onchange="getSubLayout(this,'rb-layout-select2','layout_1_sub','');">
|
||||
<option value="0">사이트 레이아웃(<?php echo getFolderName($g['path_layout'].$_layoutHexp[0])?>)</option>
|
||||
<?php $dirs = opendir($g['path_layout'])?>
|
||||
<?php while(false !== ($tpl = readdir($dirs))):?>
|
||||
<?php if($tpl=='.' || $tpl == '..' || $tpl == '_blank' || is_file($g['path_layout'].$tpl))continue?>
|
||||
<option value="<?php echo $tpl?>"<?php if($_layoutExp1[0]==$tpl):?> selected<?php endif?>><?php echo getFolderName($g['path_layout'].$tpl)?>(<?php echo $tpl?>)</option>
|
||||
<?php endwhile?>
|
||||
<?php closedir($dirs)?>
|
||||
</select>
|
||||
</div>
|
||||
<div class="col-sm-6" id="rb-layout-select2">
|
||||
<select class="form-control custom-select" name="layout_1_sub"<?php if(!$d['search']['layout']):?> disabled<?php endif?>>
|
||||
<?php if(!$d['search']['layout']):?><option>서브 레이아웃</option><?php endif?>
|
||||
<?php $dirs1 = opendir($g['path_layout'].$_layoutExp1[0])?>
|
||||
<?php while(false !== ($tpl1 = readdir($dirs1))):?>
|
||||
<?php if(!strstr($tpl1,'.php') || $tpl1=='_main.php')continue?>
|
||||
<option value="<?php echo $tpl1?>"<?php if($_layoutExp1[1]==$tpl1):?> selected<?php endif?>><?php echo str_replace('.php','',$tpl1)?></option>
|
||||
<?php endwhile?>
|
||||
<?php closedir($dirs1)?>
|
||||
</select>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group row">
|
||||
<label class="col-lg-2 col-form-label text-lg-right">
|
||||
<span class="badge badge-dark">모바일</span>
|
||||
</label>
|
||||
<div class="col-lg-10 col-xl-9">
|
||||
|
||||
<div class="form-row">
|
||||
<?php $_mlayoutExp1=explode('/',$d['search']['m_layout'])?>
|
||||
<?php if (!is_dir($g['path_layout'].$_mlayoutExp1[0])): ?>
|
||||
<div class="col-sm-12">
|
||||
<div class="alert alert-danger">
|
||||
지정된 <?php echo $g['path_layout'].$_mlayoutExp1[0] ?> 레이아웃이 존재하지 않습니다. 변경해 주세요.
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-sm-6" id="rb-mlayout-select">
|
||||
<select class="form-control custom-select" name="m_layout_1" required onchange="getSubLayout(this,'rb-layout-select4','m_layout_1_sub','custom-select');" style="letter-spacing: -1px;">
|
||||
<option value="0">사용안함 (기본 레이아웃 적용)</option>
|
||||
<option disabled>--------------------</option>
|
||||
<?php $dirs = opendir($g['path_layout'])?>
|
||||
<?php while(false !== ($tpl = readdir($dirs))):?>
|
||||
<?php if($tpl=='.' || $tpl == '..' || $tpl == '_blank' || is_file($g['path_layout'].$tpl))continue?>
|
||||
<option value="<?php echo $tpl?>"><?php echo getFolderName($g['path_layout'].$tpl)?> (<?php echo $tpl?>)</option>
|
||||
<?php endwhile?>
|
||||
<?php closedir($dirs)?>
|
||||
</select>
|
||||
</div>
|
||||
<div class="col-sm-6" id="rb-layout-select4">
|
||||
<select class="form-control custom-select" name="m_layout_1_sub">
|
||||
</select>
|
||||
</div>
|
||||
<?php else: ?>
|
||||
<div class="col-sm-6" id="rb-layout-select3">
|
||||
<select class="form-control custom-select" name="m_layout_1" required onchange="getSubLayout(this,'rb-layout-select4','m_layout_1_sub','');">
|
||||
<option value="0">사이트 레이아웃(<?php echo getFolderName($g['path_layout'].$_mlayoutHexp[0])?>)</option>
|
||||
<?php $dirs = opendir($g['path_layout'])?>
|
||||
<?php while(false !== ($tpl = readdir($dirs))):?>
|
||||
<?php if($tpl=='.' || $tpl == '..' || $tpl == '_blank' || is_file($g['path_layout'].$tpl))continue?>
|
||||
<option value="<?php echo $tpl?>"<?php if($_mlayoutExp1[0]==$tpl):?> selected<?php endif?>><?php echo getFolderName($g['path_layout'].$tpl)?>(<?php echo $tpl?>)</option>
|
||||
<?php endwhile?>
|
||||
<?php closedir($dirs)?>
|
||||
</select>
|
||||
</div>
|
||||
<div class="col-sm-6" id="rb-layout-select4">
|
||||
<select class="form-control custom-select" name="m_layout_1_sub"<?php if(!$d['search']['m_layout']):?> disabled<?php endif?>>
|
||||
<?php if(!$d['search']['m_layout']):?><option>서브 레이아웃</option><?php endif?>
|
||||
<?php $dirs1 = opendir($g['path_layout'].$_mlayoutExp1[0])?>
|
||||
<?php while(false !== ($tpl1 = readdir($dirs1))):?>
|
||||
<?php if(!strstr($tpl1,'.php') || $tpl1=='_main.php')continue?>
|
||||
<option value="<?php echo $tpl1?>"<?php if($_mlayoutExp1[1]==$tpl1):?> selected<?php endif?>><?php echo str_replace('.php','',$tpl1)?></option>
|
||||
<?php endwhile?>
|
||||
<?php closedir($dirs1)?>
|
||||
</select>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group row">
|
||||
<label class="col-lg-2 col-form-label text-lg-right">외부검색</label>
|
||||
<div class="col-lg-10 col-xl-9">
|
||||
<textarea name="searchlist" class="form-control" rows="5"><?php echo trim(implode('',file($g['path_module'].$module.'/var/search.list.txt')))?></textarea>
|
||||
<p class="form-text text-muted">
|
||||
<small>검색엔진명과 검색URL을 콤마(,)로 구분해서 등록해 주세요. 외부검색을 이용해 검색어를 선택된 검색엔진으로 연결해 줍니다.</small>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-lg-10 offset-lg-2 col-xl-9 offset-xl-2">
|
||||
<button type="submit" class="btn btn-outline-primary btn-lg my-4 btn-block" id="rb-submit-button">확인</button>
|
||||
</div>
|
||||
</div>
|
||||
</div><!-- /.card-body -->
|
||||
</form><!-- /.card -->
|
||||
|
||||
<?php endif?>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
<!-- nestable : https://github.com/dbushell/Nestable -->
|
||||
<?php getImport('nestable','jquery.nestable',false,'js')?>
|
||||
<script>
|
||||
$(document).ready(function() {
|
||||
|
||||
putCookieAlert('search_config_result') // 실행결과 알림 메시지
|
||||
$('#nestable-menu').nestable();
|
||||
$('.dd').on('change', function() {
|
||||
orderUpdate();
|
||||
});
|
||||
|
||||
<?php if (!$searchfile): ?>
|
||||
//사이트 셀렉터 출력
|
||||
$('[data-role="siteSelector"]').removeClass('d-none')
|
||||
<?php endif; ?>
|
||||
|
||||
});
|
||||
|
||||
function orderUpdate()
|
||||
{
|
||||
var f = document.forms[0];
|
||||
f.auto.value = '1';
|
||||
getIframeForAction(f);
|
||||
f.submit();
|
||||
}
|
||||
function procCheck(f)
|
||||
{
|
||||
if (f.name.value == '')
|
||||
{
|
||||
alert('검색 페이지명을 입력해 주세요. ');
|
||||
f.name.focus();
|
||||
return false;
|
||||
}
|
||||
|
||||
getIframeForAction(f);
|
||||
return confirm('정말로 실행하시겠습니까? ');
|
||||
}
|
||||
function saveCheck(f)
|
||||
{
|
||||
if(f.layout_1.value != '0') f.layout.value = f.layout_1.value + '/' + f.layout_1_sub.value;
|
||||
else f.layout.value = '';
|
||||
|
||||
if(f.m_layout_1.value != '0') f.m_layout.value = f.m_layout_1.value + '/' + f.m_layout_1_sub.value;
|
||||
else f.m_layout.value = '';
|
||||
|
||||
getIframeForAction(f);
|
||||
// return confirm('정말로 실행하시겠습니까? ');
|
||||
}
|
||||
<?php if($_nowOrderNum != count($d['search_order']) || $autoCheck=='Y'):?>
|
||||
setTimeout("orderUpdate();",100);
|
||||
<?php endif?>
|
||||
|
||||
</script>
|
||||
235
modules/search/admin/theme.php
Normal file
235
modules/search/admin/theme.php
Normal file
@@ -0,0 +1,235 @@
|
||||
<link href="<?php echo $g['s']?>/_core/css/github-markdown.css" rel="stylesheet">
|
||||
<?php getImport('jquery-markdown','jquery.markdown','0.0.10','js')?>
|
||||
|
||||
<div class="row no-gutters">
|
||||
<div class="col-sm-4 col-md-4 col-xl-3 d-none d-sm-block sidebar"><!-- 좌측영역 시작 -->
|
||||
<div class="card">
|
||||
<div class="card-header f13">
|
||||
테마 리스트
|
||||
</div>
|
||||
|
||||
<div class="list-group list-group-flush">
|
||||
<?php $i=0?>
|
||||
<?php $xdir = $g['path_module'].$module.'/themes/'?>
|
||||
<?php $tdir = $xdir.'_desktop/'?>
|
||||
<?php $dirs = opendir($tdir)?>
|
||||
<?php while(false !== ($skin = readdir($dirs))):?>
|
||||
<?php if($skin=='.' || $skin == '..' || is_file($tdir.$skin))continue?>
|
||||
<?php $i++?>
|
||||
<a href="<?php echo $g['adm_href']?>&theme=_desktop/<?php echo $skin?>" class="list-group-item list-group-item-action d-flex justify-content-between align-items-center<?php if($theme=='_desktop/'.$skin):?> border border-primary<?php endif?>">
|
||||
<span><?php echo getFolderName($tdir.$skin)?></span>
|
||||
<span class="badge badge-<?php echo $theme=='_desktop/'.$skin?'primary':'dark' ?> badge-pill"><?php echo $skin?></span>
|
||||
</a>
|
||||
<?php endwhile?>
|
||||
<?php closedir($dirs)?>
|
||||
<?php $tdir = $xdir.'_mobile/'?>
|
||||
<?php $dirs = opendir($tdir)?>
|
||||
<?php while(false !== ($skin = readdir($dirs))):?>
|
||||
<?php if($skin=='.' || $skin == '..' || is_file($tdir.$skin))continue?>
|
||||
<?php $i++?>
|
||||
<a href="<?php echo $g['adm_href']?>&theme=_mobile/<?php echo $skin?>" class="list-group-item list-group-item-action d-flex justify-content-between align-items-center<?php if($theme=='_mobile/'.$skin):?> border border-primary<?php endif?>">
|
||||
<span><?php echo getFolderName($tdir.$skin)?></span>
|
||||
<span class="badge badge-<?php echo $theme=='_mobile/'.$skin?'primary':'dark' ?> badge-pill"><?php echo $skin?></span>
|
||||
</a>
|
||||
<?php endwhile?>
|
||||
<?php closedir($dirs)?>
|
||||
</div>
|
||||
|
||||
<?php if(!$i):?>
|
||||
<div class="none">등록된 테마가 없습니다.</div>
|
||||
<?php endif?>
|
||||
|
||||
|
||||
</div> <!-- 좌측 card 끝 -->
|
||||
</div> <!-- 좌측 영역 끝 -->
|
||||
<div class="col-sm-8 col-md-8 ml-sm-auto col-xl-9">
|
||||
|
||||
<?php if($theme):?>
|
||||
<form class="card rounded-0 border-0" name="procForm" action="<?php echo $g['s']?>/" method="post" target="_action_frame_<?php echo $m?>" onsubmit="return saveCheck(this);">
|
||||
<input type="hidden" name="r" value="<?php echo $r?>" />
|
||||
<input type="hidden" name="m" value="<?php echo $module?>" />
|
||||
<input type="hidden" name="a" value="theme_config" />
|
||||
<input type="hidden" name="theme" value="<?php echo $theme?>" />
|
||||
|
||||
<div class="card-header p-0">
|
||||
<ol class="breadcrumb rounded-0 mb-0 bg-transparent text-muted">
|
||||
<?php $_theme =explode('/' , $theme); ?>
|
||||
<li class="breadcrumb-item">root</li>
|
||||
<li class="breadcrumb-item">modules</li>
|
||||
<li class="breadcrumb-item"><?php echo $module?></li>
|
||||
<li class="breadcrumb-item">themes</li>
|
||||
<li class="breadcrumb-item"><?php echo $_theme[0]?></li>
|
||||
<li class="breadcrumb-item"><?php echo $_theme[1]?></li>
|
||||
</ol>
|
||||
</div>
|
||||
|
||||
|
||||
<ul class="nav nav-tabs">
|
||||
<li class="nav-item">
|
||||
<a class="nav-link js-tooltip<?php if(!$_COOKIE['moduleBbsThemeTab']||$_COOKIE['moduleBbsThemeTab']=='readme'):?> active<?php endif?>" href="#readme" data-toggle="tab" onclick="setCookie('moduleBbsThemeTab','readme',1);" title="README.md" data-placement="bottom">
|
||||
안내문서
|
||||
</a>
|
||||
</li>
|
||||
<li class="nav-item editor">
|
||||
<a class="nav-link js-tooltip<?php if($_COOKIE['moduleBbsThemeTab']=='editor'):?> active<?php endif?>" href="#var" data-toggle="tab" onclick="setCookie('moduleBbsThemeTab','editor','1');" title="var.php" data-placement="bottom">
|
||||
설정 변수
|
||||
</a>
|
||||
</li>
|
||||
</ul>
|
||||
<div class="tab-content">
|
||||
|
||||
<div class="tab-pane <?php if(!$_COOKIE['moduleBbsThemeTab']||$_COOKIE['moduleBbsThemeTab']=='readme'):?> show active<?php endif?>" id="readme" role="tabpanel" aria-labelledby="readme-tab">
|
||||
|
||||
<?php if (is_file($g['path_module'].$module.'/themes/'.$theme.'/README.md')): ?>
|
||||
<div class="markdown-body px-4 py-0 readme">
|
||||
<?php readfile($g['path_module'].$module.'/themes/'.$theme.'/README.md')?>
|
||||
</div>
|
||||
<?php else: ?>
|
||||
|
||||
<div class="text-center text-muted d-flex align-items-center justify-content-center" style="height: calc(100vh - 10rem);">
|
||||
<div><i class="fa fa-exclamation-circle fa-3x mb-3" aria-hidden="true"></i>
|
||||
<p>테마 안내문서가 없습니다.</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if (is_file($g['path_module'].$module.'/themes/'.$theme.'/LICENSE')): ?>
|
||||
<div class="py-5 px-4">
|
||||
<h5>라이센스</h5>
|
||||
<textarea class="form-control" rows="10"><?php readfile($g['path_module'].$module.'/themes/'.$theme.'/LICENSE')?></textarea>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
<div class="tab-pane pr-2<?php if($_COOKIE['moduleBbsThemeTab']=='editor'):?> show active<?php endif?>" id="var" role="tabpanel" aria-labelledby="var-tab">
|
||||
|
||||
<div class="">
|
||||
<div class="rb-codeview">
|
||||
<div class="rb-codeview-body">
|
||||
<textarea name="theme_var" id="__code__" class="form-control" rows="30"><?php echo implode('',file($g['path_module'].$module.'/themes/'.$theme.'/_var/var.php'))?></textarea>
|
||||
</div>
|
||||
|
||||
<div class="rb-codeview-footer p-2">
|
||||
<div class="form-row mb-2">
|
||||
<div class="col">
|
||||
<div class="input-group input-group-sm">
|
||||
<div class="input-group-prepend">
|
||||
<span class="input-group-text">테마명</span>
|
||||
</div>
|
||||
<input type="text" class="form-control" name="name" value="<?php echo getFolderName($g['path_module'].$module.'/themes/'.$theme)?>">
|
||||
</div>
|
||||
</div>
|
||||
<div class="col">
|
||||
<div class="input-group input-group-sm">
|
||||
<div class="input-group-prepend">
|
||||
<span class="input-group-text">테마 폴더</span>
|
||||
</div>
|
||||
<input type="text" class="form-control" name="newLayout" value="<?php echo $theme?>">
|
||||
</div>
|
||||
</div>
|
||||
<div class="col text-right pt-2 text-muted">
|
||||
<small><?php echo count(file($g['path_module'].$module.'/themes/'.$theme.'/_var/var.php')).' lines'?></small></li>
|
||||
<small class="ml-3"><?php echo getSizeFormat(@filesize($g['path_module'].$module.'/themes/'.$theme.'/_var/var.php'),2)?></small>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div> <!--.rb-codeview -->
|
||||
</div> <!--.rb-files -->
|
||||
<div class="card-footer">
|
||||
|
||||
<button type="submit" class="btn btn-outline-primary">저장하기</button>
|
||||
<span class="ml-3 text-muted">이 테마를 사용하는 모든 게시판에 위의 설정값이 적용됩니다.</span>
|
||||
<?php if($theme):?>
|
||||
<div class="pull-right">
|
||||
<a class="btn btn-outline-danger" href="<?php echo $g['s']?>/?r=<?php echo $r?>&m=<?php echo $module?>&a=theme_delete&theme=<?php echo $theme?>" target="_action_frame_<?php echo $m?>" onclick="return confirm('정말로 이 테마를 삭제하시겠습니까? ');">테마삭제</a>
|
||||
</div>
|
||||
<?php endif?>
|
||||
|
||||
</div>
|
||||
</div><!-- /.tab-pane -->
|
||||
|
||||
</div><!-- /.tab-content -->
|
||||
|
||||
|
||||
|
||||
<?php else:?>
|
||||
|
||||
<div class="text-center text-muted d-flex align-items-center justify-content-center" style="height: calc(100vh - 10rem);">
|
||||
<div class="">
|
||||
<i class="fa fa fa-picture-o fa-3x mb-3" aria-hidden="true"></i>
|
||||
<p>테마를 선택해 주세요.</p>
|
||||
<p class="small">테마설정은 해당 테마를 사용하는 모든 프론트 페이지에 적용됩니다.</p>
|
||||
|
||||
<ul class="list list-unstyled small">
|
||||
<li>테마는 통합검색모듈 검색테마를 변경할 수 있는 요소입니다.</li>
|
||||
<li>테마설정은 통합검색모듈 프론트 페이지의 외형만 제어하며 통합검색모듈의 내부시스템에는 영향을 주지 않습니다.</li>
|
||||
<li>테마의 속성을 변경하면 해당테마를 사용하는 모든 사이트의 통합검색 관련된 페이지에 적용됩니다.</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<?php endif?>
|
||||
|
||||
</form>
|
||||
</div> <!-- 우측영역 끝 -->
|
||||
</div> <!--.row -->
|
||||
|
||||
|
||||
<?php if($d['admin']['codeeidt']):?>
|
||||
<!-- codemirror -->
|
||||
<style>
|
||||
.CodeMirror {
|
||||
font-size: 13px;
|
||||
font-weight: normal;
|
||||
font-family: Menlo,Monaco,Consolas,"Courier New",monospace !important;
|
||||
}
|
||||
</style>
|
||||
<?php getImport('codemirror','codemirror',false,'css')?>
|
||||
<?php getImport('codemirror','codemirror',false,'js')?>
|
||||
<?php getImport('codemirror','theme/'.$d['admin']['codeeidt'],false,'css')?>
|
||||
<?php getImport('codemirror','addon/display/fullscreen',false,'css')?>
|
||||
<?php getImport('codemirror','addon/display/fullscreen',false,'js')?>
|
||||
<?php getImport('codemirror','mode/htmlmixed/htmlmixed',false,'js')?>
|
||||
<?php getImport('codemirror','mode/xml/xml',false,'js')?>
|
||||
<?php getImport('codemirror','mode/javascript/javascript',false,'js')?>
|
||||
<?php getImport('codemirror','mode/clike/clike',false,'js')?>
|
||||
<?php getImport('codemirror','mode/php/php',false,'js')?>
|
||||
<?php getImport('codemirror','mode/css/css',false,'js')?>
|
||||
<script>
|
||||
|
||||
(function() {
|
||||
|
||||
$(".markdown-body").markdown();
|
||||
|
||||
var editor = CodeMirror.fromTextArea(getId('__code__'), {
|
||||
mode: "<?php echo $codeset[$codeext]?$codeset[$codeext]:'application/x-httpd-php'?>",
|
||||
indentUnit: 2,
|
||||
lineNumbers: true,
|
||||
matchBrackets: true,
|
||||
indentWithTabs: true,
|
||||
theme: '<?php echo $d['admin']['codeeidt']?>'
|
||||
});
|
||||
editor.setSize('100%','500px');
|
||||
_isCodeEdit = true;
|
||||
})();
|
||||
|
||||
</script>
|
||||
<!-- @codemirror -->
|
||||
<?php endif?>
|
||||
|
||||
|
||||
<script type="text/javascript">
|
||||
//<![CDATA[
|
||||
function saveCheck(f)
|
||||
{
|
||||
return confirm('정말로 실행하시겠습니까? ');
|
||||
}
|
||||
//]]>
|
||||
</script>
|
||||
14
modules/search/admin/var/var.joint.php
Normal file
14
modules/search/admin/var/var.joint.php
Normal file
@@ -0,0 +1,14 @@
|
||||
<div id="mjointbox">
|
||||
|
||||
<div class="title">
|
||||
이 모듈(통합검색)을 연결하시겠습니까?
|
||||
</div>
|
||||
|
||||
<input type="button" value="연결" class="btn btn-light" onclick="dropJoint('<?php echo $g['s']?>/?r=<?php echo $r?>&m=<?php echo $smodule?>');" />
|
||||
|
||||
</div>
|
||||
|
||||
<style type="text/css">
|
||||
#mjointbox {}
|
||||
#mjointbox .title {border-bottom:#dfdfdf dashed 1px;padding:0 0 10px 0;margin:0 0 20px 0;}
|
||||
</style>
|
||||
4
modules/search/admin/var/var.menu.php
Normal file
4
modules/search/admin/var/var.menu.php
Normal file
@@ -0,0 +1,4 @@
|
||||
<?php
|
||||
$d['amenu']['main'] = '환경설정';
|
||||
$d['amenu']['theme'] = '테마';
|
||||
?>
|
||||
3
modules/search/for-searching/_desktop/example1.css
Normal file
3
modules/search/for-searching/_desktop/example1.css
Normal file
@@ -0,0 +1,3 @@
|
||||
#rb-search-search-example1 {
|
||||
|
||||
}
|
||||
71
modules/search/for-searching/_desktop/example1.php
Normal file
71
modules/search/for-searching/_desktop/example1.php
Normal file
@@ -0,0 +1,71 @@
|
||||
<?php
|
||||
/**************************************************************
|
||||
|
||||
아래의 변수를 이용합니다.
|
||||
$_iscallpage 통합검색 이거나 더보기일경우 true 아니면 false
|
||||
$where 검색위치
|
||||
$keyword 검색키워드
|
||||
$orderby (desc 최신순 / asc 오래된순)
|
||||
$d['search']['num1'] 전체검색 출력수
|
||||
$d['search']['num2'] 전용검색 한 페이당 출력수
|
||||
$d['search']['term'] 검색기간(월단위)
|
||||
|
||||
검색결과 DIV id 정의방법 : <div id="rb-search-모듈id-검색파일명"> ... </div>
|
||||
|
||||
***************************************************************
|
||||
|
||||
검색결과 추출 예제 ::
|
||||
|
||||
$sqlque = ''; // 검색용 SQL 초기화
|
||||
if ($keyword)
|
||||
{
|
||||
$sqlque .= getSearchSql('검색필드',$keyword,'','or'); //검색필드 설정방법 : 1개의 필드 -> 필드명 , 복수의 필드 -> 필드명을 |(파이프) 로 구분
|
||||
}
|
||||
|
||||
// 더보기 검색일 경우에만 실행함
|
||||
if ($swhere == $_key)
|
||||
{
|
||||
$sort = 'uid'; // 기본 정렬필드
|
||||
$RCD = getDbArray($table['테이블명'],$sqlque,'*',$sort,$orderby,$d['search']['num'.($swhere=='all'?1:2)],$p);
|
||||
while($_R = db_fetch_array($RCD))
|
||||
{
|
||||
echo $_R['필드네임'];
|
||||
}
|
||||
}
|
||||
$_ResultArray['num'][$_key] = getDbRows($table['테이블명'],$sqlque); // 검색어에 해당되는 결과갯수 <- 무조건 실행해야 됨
|
||||
|
||||
**************************************************************
|
||||
|
||||
아래의 예제는 실제로 페이지를 검색하는 샘플입니다.
|
||||
페이징,더보기,검색결과 없을경우 안내등은 모두 자동으로 처리되니 결과 리스트만 출력해 주시면 됩니다.
|
||||
최초 설치시 "이용약관" 이나 "개인정보" 로 검색하시면 결과값을 얻으실 수 있습니다.
|
||||
|
||||
**************************************************************/
|
||||
?>
|
||||
|
||||
|
||||
|
||||
|
||||
<?php
|
||||
$sqlque = 'uid';
|
||||
$sqlque .= getSearchSql('id|name',$keyword,'','or'); // 페이지코드와 페이지명 검색
|
||||
|
||||
if($_iscallpage):
|
||||
$RCD = getDbArray($table['s_page'],$sqlque,'*','uid',$orderby,$d['search']['num'.($swhere=='all'?1:2)],$p);
|
||||
?>
|
||||
|
||||
|
||||
<div id="rb-search-search-example1">
|
||||
<ol>
|
||||
<?php while($_R=db_fetch_array($RCD)):?>
|
||||
<li><a href="<?php echo $g['s']?>/?r=<?php echo $r?>&mod=<?php echo $_R['id']?>"><?php echo $_R['name']?></a></li>
|
||||
<?php endwhile?>
|
||||
</ol>
|
||||
</div>
|
||||
|
||||
|
||||
<?php
|
||||
endif;
|
||||
$_ResultArray['num'][$_key] = getDbRows($table['s_page'],$sqlque);
|
||||
?>
|
||||
|
||||
21
modules/search/for-searching/_desktop/example2.php
Normal file
21
modules/search/for-searching/_desktop/example2.php
Normal file
@@ -0,0 +1,21 @@
|
||||
<?php
|
||||
if($_iscallpage):
|
||||
?>
|
||||
|
||||
|
||||
<div id="rb-search-search-example2">
|
||||
<ol>
|
||||
<li>검색결과 예제입니다.</li>
|
||||
<li>검색결과 예제입니다.</li>
|
||||
<li>검색결과 예제입니다.</li>
|
||||
<li>검색결과 예제입니다.</li>
|
||||
<li>검색결과 예제입니다.</li>
|
||||
</ol>
|
||||
</div>
|
||||
|
||||
|
||||
<?php
|
||||
endif;
|
||||
$_ResultArray['num'][$_key] = 5;
|
||||
?>
|
||||
|
||||
15
modules/search/for-searching/_desktop/example3.php
Normal file
15
modules/search/for-searching/_desktop/example3.php
Normal file
@@ -0,0 +1,15 @@
|
||||
<?php
|
||||
if($_iscallpage):
|
||||
?>
|
||||
|
||||
|
||||
<div id="rb-search-search-example3">
|
||||
$_ResultArray['num'][$_key] 가 0 이므로 이 내용은 검색결과 페이지 출력되지 않습니다.
|
||||
</div>
|
||||
|
||||
|
||||
<?php
|
||||
endif;
|
||||
$_ResultArray['num'][$_key] = 0;
|
||||
?>
|
||||
|
||||
37
modules/search/main.php
Normal file
37
modules/search/main.php
Normal file
@@ -0,0 +1,37 @@
|
||||
<?php
|
||||
if(!defined('__KIMS__')) exit;
|
||||
|
||||
$g['searchVarForSite'] = $g['path_var'].'site/'.$r.'/search.var.php';
|
||||
$_tmpdfile = file_exists($g['searchVarForSite']) ? $g['searchVarForSite'] : $g['dir_module'].'var/var.search.php';
|
||||
include_once $_tmpdfile;
|
||||
|
||||
if ($g['mobile']&&$_SESSION['pcmode']!='Y'){
|
||||
include_once $g['dir_module'].'var/var.order.mobile.php';
|
||||
}else{
|
||||
include_once $g['dir_module'].'var/var.order.desktop.php';
|
||||
}
|
||||
|
||||
$swhere = $swhere ? $swhere : 'all';
|
||||
$_ResultArray = array();
|
||||
$_HM['layout'] = $d['search']['layout'];
|
||||
|
||||
if ($g['mobile']&&$_SESSION['pcmode']!='Y')
|
||||
{
|
||||
$_HM['m_layout'] = $d['search']['m_layout'] ?$d['search']['m_layout'] : $d['search']['layout'];
|
||||
$d['search']['theme'] = $d['search']['m_theme'] ? $d['search']['m_theme'] : $d['search']['theme'];
|
||||
}
|
||||
|
||||
$g['dir_module_skin'] = $g['dir_module'].'/themes/'.$d['search']['theme'].'/';
|
||||
$g['url_module_skin'] = $g['url_module'].'/themes/'.$d['search']['theme'];
|
||||
$g['img_module_skin'] = $g['url_module_skin'].'/images';
|
||||
|
||||
$g['dir_module_mode'] = $g['dir_module_skin'].'main';
|
||||
$g['url_module_mode'] = $g['url_module_skin'].'/main';
|
||||
|
||||
$g['url_reset'] = $_HS['rewrite']? RW('m=search'):$g['s'].'/?r='.$r.'&m='.$m;
|
||||
$g['url_where'] = $g['url_reset'].($q?($_HS['rewrite']?'?':'&').'q='.urlencode($q):'').($sort?'&sort='.$sort:'').($orderby?'&sort='.$orderby:'').'&swhere=';
|
||||
|
||||
$g['push_location'] = '<li class="active">'.$_HMD['name'].'</li>';
|
||||
|
||||
$g['main'] = $g['dir_module_mode'].'.php';
|
||||
?>
|
||||
1
modules/search/name.txt
Normal file
1
modules/search/name.txt
Normal file
@@ -0,0 +1 @@
|
||||
통합검색
|
||||
21
modules/search/themes/_desktop/bs4-default/LICENSE
Normal file
21
modules/search/themes/_desktop/bs4-default/LICENSE
Normal file
@@ -0,0 +1,21 @@
|
||||
The RBL License
|
||||
|
||||
Copyright (c) 2011-2018 Redblock, Inc.
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in
|
||||
all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||
THE SOFTWARE.
|
||||
6
modules/search/themes/_desktop/bs4-default/README.md
Normal file
6
modules/search/themes/_desktop/bs4-default/README.md
Normal file
@@ -0,0 +1,6 @@
|
||||
|
||||
# 부스트트랩 4 기본형
|
||||
|
||||
테스크탑 전용 통합검색모듈 테마 입니다.
|
||||
|
||||
## 주요 기능
|
||||
116
modules/search/themes/_desktop/bs4-default/main.css
Normal file
116
modules/search/themes/_desktop/bs4-default/main.css
Normal file
@@ -0,0 +1,116 @@
|
||||
#rb-search-body .container {
|
||||
max-width: 1100px !important;
|
||||
}
|
||||
|
||||
#rb-search-body .logo {
|
||||
display: inline-block;
|
||||
padding-top: .3125rem;
|
||||
padding-bottom: .3125rem;
|
||||
font-size: 1.8rem;
|
||||
line-height: inherit;
|
||||
white-space: nowrap;
|
||||
color: rgba(0,0,0,.8);
|
||||
}
|
||||
#rb-search-body .logo:hover {
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
|
||||
[data-role="searchform"] .input-group {
|
||||
border: 1px solid #007bff;
|
||||
}
|
||||
|
||||
[data-role="searchform"] .form-control {
|
||||
font-weight: 600;
|
||||
color: #000
|
||||
}
|
||||
|
||||
[data-role="searchform"] .form-control:focus {
|
||||
outline: 0;
|
||||
box-shadow: none
|
||||
}
|
||||
|
||||
[data-role="lnb"] {
|
||||
padding: 0 1rem
|
||||
}
|
||||
|
||||
[data-role="lnb"] .nav-item {
|
||||
position: relative;
|
||||
}
|
||||
|
||||
[data-role="lnb"] .nav-item .nav-link {
|
||||
padding: .7rem 1rem;
|
||||
color: #333;
|
||||
font-size: 1.05rem;
|
||||
letter-spacing: -.5px;
|
||||
}
|
||||
[data-role="lnb"] .nav-item:first-child .nav-link {
|
||||
padding-left: 0
|
||||
}
|
||||
|
||||
[data-role="lnb"] .nav-item.active .nav-link {
|
||||
color: #007bff
|
||||
}
|
||||
|
||||
[data-role="lnb"] .nav-item.active::after {
|
||||
position: absolute;
|
||||
bottom:-1px;
|
||||
left: 1rem;
|
||||
right:1rem;
|
||||
top: auto;
|
||||
height: 2px;
|
||||
background-color: #007bff;
|
||||
content: ''
|
||||
}
|
||||
[data-role="lnb"] .nav-item:first-child.active::after {
|
||||
left: 0;
|
||||
}
|
||||
|
||||
[data-role="section-list"] [data-role="section-item"] {
|
||||
margin-top: 2.5rem;
|
||||
padding-top: 1.5rem;
|
||||
border-top: 0.0625rem solid #dee2e6
|
||||
}
|
||||
|
||||
[data-role="section-list"] [data-role="section-item"]:first-child {
|
||||
margin-top: 0;
|
||||
padding-top: 0;
|
||||
border-top: none
|
||||
}
|
||||
|
||||
[data-role="section-item"] .media-body h5 a {
|
||||
font-size: 14px;
|
||||
color: #1a0dab;
|
||||
text-decoration: underline;
|
||||
}
|
||||
[data-role="section-item"] .media-body h5 a:visited {
|
||||
color: #8c0198;
|
||||
}
|
||||
|
||||
[data-role="section-item"] .media-body {
|
||||
font-size: 12px;
|
||||
color: #333;
|
||||
}
|
||||
|
||||
[data-role="section-item"] .media-body time {
|
||||
font-size: 12px;
|
||||
color: #777;
|
||||
}
|
||||
|
||||
|
||||
.footer_comm .link_info {
|
||||
font-size: 12px;
|
||||
color: #777;
|
||||
}
|
||||
.footer_comm .txt_bar {
|
||||
font-size: 12px;
|
||||
padding: 0 4px;
|
||||
color: #ededed;
|
||||
}
|
||||
|
||||
.mark, mark {
|
||||
padding: 0;
|
||||
background-color: transparent;
|
||||
font-weight: bold;
|
||||
color: inherit;
|
||||
}
|
||||
328
modules/search/themes/_desktop/bs4-default/main.php
Normal file
328
modules/search/themes/_desktop/bs4-default/main.php
Normal file
@@ -0,0 +1,328 @@
|
||||
|
||||
|
||||
<div id="rb-search-body" class="mb-4">
|
||||
|
||||
<header class="header">
|
||||
<form name="RbSearchForm" action="<?php echo $_HS['rewrite']? RW('m=search'):$g['s'].'/'?>" class="py-4" role="form" data-role="searchform">
|
||||
|
||||
<?php if (!$_HS['rewrite']): ?>
|
||||
<input type="hidden" name="r" value="<?php echo $r?>">
|
||||
<input type="hidden" name="m" value="<?php echo $m?>">
|
||||
<?php endif; ?>
|
||||
|
||||
<input type="hidden" name="where" value="<?php echo $where?>">
|
||||
<input type="hidden" name="swhere" value="<?php echo $swhere?>">
|
||||
<input type="hidden" name="sort" value="<?php echo $sort?>">
|
||||
<input type="hidden" name="orderby" value="<?php echo $orderby?>">
|
||||
|
||||
<div class="<?php echo $d['layout']['header_container'] ?>">
|
||||
<div class="row align-items-center">
|
||||
|
||||
<div class="col-8 pr-0">
|
||||
|
||||
<div class="media align-items-center">
|
||||
<h1 class="h2 mb-0 mr-4">
|
||||
<a class="navbar-brand" href="<?php echo RW(0) ?>"
|
||||
style="background-image:url(<?php echo $d['layout']['header_logo']?$g['url_var_site'].'/'.$d['layout']['header_logo'].$g['wcache']:''?>);background-size:<?php echo $d['layout']['header_logo_size'] ?>%">
|
||||
<?php echo !$d['layout']['header_logo']?$d['layout']['header_title'] :'' ?>
|
||||
</a>
|
||||
</h1>
|
||||
<div class="media-body">
|
||||
<div class="input-group input-group-lg shadow-sm dropdown">
|
||||
<input type="search" name="q" class="form-control bg-white border-0 rounded-0" value="<?php echo $q?>" data-plugin="autocomplete" autocomplete="off" required>
|
||||
<div class="input-group-append">
|
||||
<button class="btn btn-outline-primary border-0 rounded-0" type="submit"><i class="fa fa-search"></i></button>
|
||||
</div>
|
||||
</div><!-- /.input-group -->
|
||||
</div><!-- /.media-body -->
|
||||
</div>
|
||||
</div><!-- /.col-8 -->
|
||||
|
||||
<div class="col-4">
|
||||
|
||||
|
||||
</div><!-- /.col-4 -->
|
||||
</div><!-- /.row -->
|
||||
</div><!-- /.container -->
|
||||
</form>
|
||||
|
||||
<nav class="navbar navbar-expand-lg navbar-light bg-white border-top border-bottom" data-role="lnb">
|
||||
<div class="container">
|
||||
<ul class="navbar-nav mr-auto">
|
||||
<li class="nav-item <?php if($swhere=='all'):?> active<?php endif?>">
|
||||
<a class="nav-link" href="<?php echo $g['url_where']?>all">통합검색</a>
|
||||
</li>
|
||||
<?php $_ResultArray['spage']=0;foreach($d['search_order'] as $_key => $_val):if(!strstr($_val[1],'['.$r.']'))continue?>
|
||||
<li class="nav-item<?php if($swhere==$_key):?> active<?php endif?>" id="nav_<?php echo $_key?>" data-num="">
|
||||
<a class="nav-link" href="<?php echo $g['url_where'].$_key?>" id=nav_<?php echo $_key?>>
|
||||
<?php echo $_val[0]?>
|
||||
</a>
|
||||
</li>
|
||||
<?php $_ResultArray['spage']++;endforeach?>
|
||||
</ul>
|
||||
<?php if($q):?>
|
||||
<span class="navbar-text f13">
|
||||
총 <strong id="rb_sresult_num_all">0</strong> 건이 검색 되었습니다.
|
||||
</span>
|
||||
<?php endif?>
|
||||
<div class="ml-3">
|
||||
<select class="form-control custom-select custom-select-sm" data-header="정열방식" onchange="searchSortChange(this);">
|
||||
<option value="desc"<?php if($orderby=='desc'):?> selected<?php endif?>>최신순</option>
|
||||
<option value="asc"<?php if($orderby=='asc'):?> selected<?php endif?>>과거순</option>
|
||||
</select>
|
||||
</div>
|
||||
</div><!-- /.container -->
|
||||
</nav>
|
||||
</header>
|
||||
|
||||
<main>
|
||||
<div class="<?php echo $d['layout']['home_container'] ?>">
|
||||
|
||||
<div class="row">
|
||||
<main class="col-8 border-right py-4" data-plugin="markjs">
|
||||
|
||||
<div data-role="section-list">
|
||||
<?php $_ResultArray['num']=array()?>
|
||||
<?php if($q):?>
|
||||
<?php foreach($d['search_order'] as $_key => $_val):if(!strstr($_val[1],'['.$r.']'))continue?>
|
||||
<?php $_iscallpage=($swhere == 'all' || $swhere == $_key)?>
|
||||
<?php if($_iscallpage):?>
|
||||
<?php if(is_file($_val[2].'.css')) echo '<link href="'.$_val[2].'.css" rel="stylesheet">'?>
|
||||
<section id="rb_search_panel_<?php echo $_key?>" class="d-none" data-role="section-item">
|
||||
<header class="mb-3">
|
||||
<strong><?php echo $_val[0]?></strong>
|
||||
<small><span class="text-muted" data-role="sresult_num_tt_<?php echo $_key?>"></span> 건</small>
|
||||
</header>
|
||||
<?php endif?>
|
||||
|
||||
<!-- 검색결과 -->
|
||||
<?php include $_val[2].'.php' ?>
|
||||
<!-- @검색결과 -->
|
||||
|
||||
<?php if($_iscallpage):?>
|
||||
<?php if($swhere==$_key):?>
|
||||
<footer>
|
||||
<ul class="pagination justify-content-center mb-0">
|
||||
<script>getPageLink(5,<?php echo $p?>,<?php echo getTotalPage($_ResultArray['num'][$_key],$d['search']['num2'])?>,'');</script>
|
||||
</ul>
|
||||
</footer>
|
||||
<?php else:?>
|
||||
<?php if($_ResultArray['num'][$_key] > $d['search']['num1']):?>
|
||||
<footer>
|
||||
<div class="rb-more-search">
|
||||
<a href="<?php echo $g['url_where'].$_key?>">더보기 <i class="fa fa-angle-right"></i></a>
|
||||
</div>
|
||||
</footer>
|
||||
<?php endif?>
|
||||
<?php endif?>
|
||||
</section>
|
||||
<?php endif?>
|
||||
<?php endforeach?>
|
||||
</div>
|
||||
|
||||
<section id="search_no_result" class="d-none my-5">
|
||||
<h5 class="mb-4"><strong>'<?php echo $q ?>'</strong> 에 대한 검색결과가 없습니다.</h5>
|
||||
<ul class="list-unstyled text-muted f13">
|
||||
<li>ㆍ검색어의 단어 수를 줄이거나, 보다 일반적인 단어로 검색해 보세요.</li>
|
||||
<li>ㆍ두 단어 이상의 키워드로 검색 하신 경우, 정확하게 띄어쓰기를 한 후 검색해 보세요.</li>
|
||||
<li>ㆍ키워드에 있는 특수문자를 뺀 후에 검색해 보세요.</li>
|
||||
</ul>
|
||||
</section>
|
||||
|
||||
<?php else:?>
|
||||
|
||||
<section id="rb-searchresult-none">
|
||||
<div class="text-center p-5 text-muted">
|
||||
검색어를 입력해 주세요.
|
||||
</div>
|
||||
</section>
|
||||
<?php endif?>
|
||||
<section id="rb-searchpage-none" class="d-none">
|
||||
<h3>검색 페이지가 설정되어 있지 않습니다.</h3>
|
||||
</section>
|
||||
</main>
|
||||
<aside class="col-4 py-4">
|
||||
|
||||
<?php
|
||||
$recnum = 10;
|
||||
$sort = $sort ? $sort : 'hit';
|
||||
$orderby= $orderby ? $orderby : 'desc';
|
||||
$query = 'site='.$s.' and ';
|
||||
$_WHERE1= $query.'date >= '.date('Ymd', strtotime('-1 month'));
|
||||
$_WHERE2= 'keyword,sum(hit) as hit';
|
||||
$RCD = getDbSelect($table['s_tag'],$_WHERE1.' group by keyword order by '.$sort.' '.$orderby.' limit 0,'.$recnum,$_WHERE2);
|
||||
?>
|
||||
|
||||
<section data-role="section-item">
|
||||
<header class="d-flex justify-content-between">
|
||||
<strong>기간별 주요 키워드 </strong>
|
||||
<small class="text-muted"><?php echo date("m/d", strtotime("-1 month")).'~'. date("m/d", strtotime("now"))?></small>
|
||||
</header>
|
||||
|
||||
<div class="mt-2">
|
||||
<div class="row mx-0">
|
||||
<?php $j=0;while($G=db_fetch_array($RCD)):$j++?>
|
||||
|
||||
<div class="col-6 bg-light py-1 mb-1">
|
||||
<a class="text-reset d-block f13" href="<?php echo $g['s']?>/?r=<?php echo $r?>&m=search&q=<?php echo urlencode($G['keyword'])?>" title="<?php echo $G['keyword']?>">
|
||||
<span class="badge badge-light mr-2"><?php echo $j?>.</span>
|
||||
<?php echo getStrCut($G['keyword'],6,'..')?>
|
||||
<small class="text-muted"><?php echo $G['hit']?>건</small>
|
||||
</a>
|
||||
</div>
|
||||
|
||||
<?php endwhile?>
|
||||
<?php if(!$j):?>
|
||||
<div class="nodata">지정된 기간내에 기록된 키워드가 없습니다.</div>
|
||||
<?php endif?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
</section>
|
||||
|
||||
|
||||
</aside>
|
||||
</div><!-- /.row -->
|
||||
</div><!-- /.container -->
|
||||
</main>
|
||||
|
||||
<footer class="border-top">
|
||||
|
||||
<div class="pt-5 text-center">
|
||||
<form name="RbSearchForm2" action="<?php echo $_HS['rewrite']? RW('m=search'):$g['s'].'/'?>" class="mx-auto" role="form" data-role="searchform" style="width :460px">
|
||||
|
||||
<?php if (!$_HS['rewrite']): ?>
|
||||
<input type="hidden" name="r" value="<?php echo $r?>">
|
||||
<input type="hidden" name="m" value="<?php echo $m?>">
|
||||
<?php endif; ?>
|
||||
|
||||
<input type="hidden" name="where" value="<?php echo $where?>">
|
||||
<input type="hidden" name="swhere" value="<?php echo $swhere?>">
|
||||
<input type="hidden" name="sort" value="<?php echo $sort?>">
|
||||
<input type="hidden" name="orderby" value="<?php echo $orderby?>">
|
||||
|
||||
<div class="input-group input-group-lg shadow-sm">
|
||||
<input type="text" name="q" class="form-control bg-white border-0 rounded-0" value="<?php echo $q?>" autocomplete="off" required>
|
||||
<div class="input-group-append">
|
||||
<button class="btn btn-outline-primary border-0 rounded-0" type="submit"><i class="fa fa-search"></i></button>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
|
||||
<div class="footer_comm mt-4 mb-5">
|
||||
<a href="<?php echo RW('mod=policy')?>" class="link_info">개인정보취급방침</a>
|
||||
<span class="txt_bar">|</span>
|
||||
<a href="<?php echo RW('mod=privacy')?>" class="link_info">이용약관</a>
|
||||
<span class="txt_bar">|</span>
|
||||
<span class="link_info">© <?php echo $d['layout']['company_name'] ?> <?php echo $date['year']?></span>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</footer>
|
||||
|
||||
</div>
|
||||
|
||||
<!-- markjs js : https://github.com/julmot/mark.js -->
|
||||
<?php getImport('markjs','jquery.mark.min','8.11.1','js')?>
|
||||
|
||||
<!-- jQuery-Autocomplete : https://github.com/devbridge/jQuery-Autocomplete -->
|
||||
<?php getImport('jQuery-Autocomplete','jquery.autocomplete.min','1.3.0','js') ?>
|
||||
|
||||
|
||||
<script>
|
||||
|
||||
document.title = '<?php echo $q?$q.'-':''?> 검색 | <?php echo $g['browtitle']?>';
|
||||
|
||||
function searchSortChange(obj)
|
||||
{
|
||||
var f = document.RbSearchForm;
|
||||
f.orderby.value = obj.value;
|
||||
f.submit();
|
||||
}
|
||||
|
||||
// Textarea 또는 Input의 끝으로 커서 이동
|
||||
jQuery.fn.putCursorAtEnd = function() {
|
||||
return this.each(function() {
|
||||
var $el = $(this),
|
||||
el = this;
|
||||
if (!$el.is(":focus")) {
|
||||
$el.focus();
|
||||
}
|
||||
if (el.setSelectionRange) {
|
||||
var len = $el.val().length * 2;
|
||||
setTimeout(function() {
|
||||
el.setSelectionRange(len, len);
|
||||
}, 1);
|
||||
} else {
|
||||
$el.val($el.val());
|
||||
}
|
||||
this.scrollTop = 999999;
|
||||
});
|
||||
};
|
||||
|
||||
|
||||
<?php $total = 0?>
|
||||
|
||||
$(function () {
|
||||
|
||||
<?php foreach($_ResultArray['num'] as $_key => $_val):$total+=$_val?>
|
||||
|
||||
if ($('[data-role="sresult_num_tt_<?php echo $_key?>"]')) {
|
||||
$('[data-role="sresult_num_tt_<?php echo $_key?>"]').text('<?php echo $_val?>')
|
||||
}
|
||||
|
||||
<?php if($_val):?>
|
||||
$('#rb_search_panel_<?php echo $_key?>').removeClass('d-none').addClass('active')
|
||||
$('#nav_<?php echo $_key?>').attr('data-num',<?php echo $_val?>);
|
||||
<?php else: ?>
|
||||
$('#rb_search_panel_<?php echo $_key?>').remove()
|
||||
<?php endif?>
|
||||
|
||||
<?php endforeach?>
|
||||
|
||||
var search_result_total = <?php echo $swhere=='all'?$total:$_ResultArray['num'][$swhere]?>;
|
||||
if(search_result_total==0){
|
||||
$("#search_no_result").removeClass("d-none");
|
||||
}
|
||||
$('#rb_sresult_num_all').text(search_result_total)
|
||||
$('[name="RbSearchForm"]').find('[name="q"]').focus().putCursorAtEnd()
|
||||
|
||||
<?php if(!$_ResultArray['spage']):?>
|
||||
if(getId('rb-sortbar')) getId('rb-sortbar').className = 'd-none';
|
||||
<?php endif?>
|
||||
|
||||
// marks.js
|
||||
$('[data-plugin="markjs"]').mark("<?php echo $q ?>");
|
||||
|
||||
$('[data-plugin="autocomplete"]').autocomplete({
|
||||
width : 467,
|
||||
lookup: function (query, done) {
|
||||
|
||||
$.getJSON(rooturl+"/?m=tag&a=searchtag", {q: query}, function(res){
|
||||
var sg_tag = [];
|
||||
var data_arr = res.taglist.split(',');//console.log(data.usernames);
|
||||
$.each(data_arr,function(key,tag){
|
||||
var tagData = tag.split('|');
|
||||
var keyword = tagData[0];
|
||||
var hit = tagData[1];
|
||||
sg_tag.push({"value":keyword,"data":hit});
|
||||
});
|
||||
var result = {
|
||||
suggestions: sg_tag
|
||||
};
|
||||
done(result);
|
||||
});
|
||||
},
|
||||
onSelect: function (suggestion) {
|
||||
if ($('[data-plugin="autocomplete"]').val().length >= 1) {
|
||||
$('[name="RbSearchForm"]').submit();
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
})
|
||||
|
||||
</script>
|
||||
1
modules/search/themes/_desktop/bs4-default/name.txt
Normal file
1
modules/search/themes/_desktop/bs4-default/name.txt
Normal file
@@ -0,0 +1 @@
|
||||
부스트트랩 4 기본형
|
||||
21
modules/search/themes/_mobile/rc-default/LICENSE
Normal file
21
modules/search/themes/_mobile/rc-default/LICENSE
Normal file
@@ -0,0 +1,21 @@
|
||||
The RBL License
|
||||
|
||||
Copyright (c) 2011-2018 Redblock, Inc.
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in
|
||||
all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||
THE SOFTWARE.
|
||||
6
modules/search/themes/_mobile/rc-default/README.md
Normal file
6
modules/search/themes/_mobile/rc-default/README.md
Normal file
@@ -0,0 +1,6 @@
|
||||
|
||||
# 알씨 기본형
|
||||
|
||||
모바일 전용 통합검색 테마 입니다.
|
||||
|
||||
## 주요 기능
|
||||
172
modules/search/themes/_mobile/rc-default/component.js
Normal file
172
modules/search/themes/_mobile/rc-default/component.js
Normal file
@@ -0,0 +1,172 @@
|
||||
var modal_search = $('#modal-search');
|
||||
var modal_search_none = '<div class="p-5 text-xs-center text-muted" data-role="none">검색된 자료가 없습니다.</div>';
|
||||
|
||||
function getSearchResult(settings) {
|
||||
var wrapper = settings.wrapper;
|
||||
var start = settings.start;
|
||||
var keyword = settings.keyword;
|
||||
var sort = settings.sort;
|
||||
var recnum = settings.recnum;
|
||||
var markup_file = settings.markup_file;
|
||||
var none = settings.none;
|
||||
|
||||
var totalPage = settings.totalPage;
|
||||
var totalNUM = settings.totalNUM;
|
||||
var currentPage =1; // 처음엔 무조건 1, 아래 더보기 진행되면서 +1 증가
|
||||
var prevNUM = currentPage * recnum;
|
||||
var moreNUM = totalNUM - prevNUM ;
|
||||
|
||||
wrapper.find('[data-role="list-post"]').loader({ position: 'inside' });
|
||||
|
||||
$.post(rooturl+'/?r='+raccount+'&m=post&a=get_postSearch',{
|
||||
start: start,
|
||||
keyword : keyword,
|
||||
sort : sort,
|
||||
recnum : recnum,
|
||||
p : currentPage,
|
||||
markup_file : markup_file
|
||||
},function(response,status){
|
||||
if(status=='success'){
|
||||
var result = $.parseJSON(response);
|
||||
var list=result.list;
|
||||
var num=result.num;
|
||||
|
||||
if (list) wrapper.find('[data-role="list-post"]').html(list)
|
||||
else wrapper.find('[data-role="list-post"]').html(none)
|
||||
|
||||
wrapper.find('[data-role="keyword-reset"]').removeClass("hidden");
|
||||
wrapper.find('[data-plugin="timeago"]').timeago();
|
||||
|
||||
$('[data-role="search"]').find('[name="keyword"]').blur();
|
||||
|
||||
//무한 스크롤
|
||||
wrapper.closest('.content').infinitescroll({
|
||||
dataSource: function(helpers, callback){
|
||||
var nextPage = parseInt(currentPage)+1;
|
||||
if (totalPage>currentPage) {
|
||||
$.post(rooturl+'/?r='+raccount+'&m=post&a=get_postSearch',{
|
||||
start: start,
|
||||
sort: sort,
|
||||
recnum : recnum,
|
||||
markup_file : markup_file,
|
||||
p : nextPage
|
||||
},function(response) {
|
||||
var result = $.parseJSON(response);
|
||||
var error = result.error;
|
||||
var list=result.list;
|
||||
if(error) alert(result.error);
|
||||
callback({ content: list });
|
||||
|
||||
currentPage++; // 현재 페이지 +1
|
||||
console.log(currentPage+'페이지 불러옴')
|
||||
wrapper.find('[data-plugin="timeago"]').timeago();
|
||||
//wrapper.find('[data-plugin="markjs"]').mark(keyword); // marks.js
|
||||
});
|
||||
} else {
|
||||
callback({ end: true });
|
||||
console.log('더이상 불러올 페이지가 없습니다.')
|
||||
}
|
||||
},
|
||||
appendToEle : wrapper,
|
||||
percentage : 95, // 95% 아래로 스크롤할때 다움페이지 호출
|
||||
hybrid : false // true: 버튼형, false: 자동
|
||||
});
|
||||
|
||||
|
||||
} else {
|
||||
alert(status);
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
} // getSearchResult
|
||||
|
||||
//검색 모달이 열렸을때
|
||||
modal_search.on('shown.rc.modal', function () {
|
||||
var modal = $(this);
|
||||
setTimeout(function() {
|
||||
modal_search.find('[name="keyword"]').val('').focus();
|
||||
}, 100);
|
||||
|
||||
$('#modal-post-view').find('[data-act="pauseVideo"]').click(); //유튜브 미니플레이어 재생정지
|
||||
|
||||
modal_search.find('[name="keyword"]').autocomplete({
|
||||
lookup: function (query, done) {
|
||||
|
||||
$.getJSON(rooturl+"/?m=tag&a=searchtag", {q: query}, function(res){
|
||||
var sg_tag = [];
|
||||
var data_arr = res.taglist.split(',');//console.log(data.usernames);
|
||||
$.each(data_arr,function(key,tag){
|
||||
var tagData = tag.split('|');
|
||||
var keyword = tagData[0];
|
||||
var hit = tagData[1];
|
||||
sg_tag.push({"value":keyword,"data":hit});
|
||||
});
|
||||
var result = {
|
||||
suggestions: sg_tag
|
||||
};
|
||||
done(result);
|
||||
});
|
||||
},
|
||||
onSelect: function (suggestion) {
|
||||
if (modal_search.find('[name="keyword"]').val().length >= 1) {
|
||||
modal_search.find('form').submit();
|
||||
console.log('검색')
|
||||
}
|
||||
}
|
||||
});
|
||||
})
|
||||
|
||||
//검색실행
|
||||
modal_search.find('form').submit( function(e){
|
||||
var modal = modal_search;
|
||||
var keyword = modal_search.find('[name="keyword"]').val();
|
||||
e.preventDefault();
|
||||
e.stopPropagation();
|
||||
|
||||
getSearchResult({
|
||||
wrapper : modal,
|
||||
keyword : keyword,
|
||||
totalNUM : '',
|
||||
totalPage : '',
|
||||
recnum : '5',
|
||||
totalPage : '',
|
||||
sort : 'gid',
|
||||
markup_file : 'search-row',
|
||||
none : modal_search_none
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
// 검색버튼과 검색어 초기화 버튼 동적 출력
|
||||
modal_search.find('[name="keyword"]').on('keyup', function(event) {
|
||||
var modal = modal_search
|
||||
modal.find('[data-role="keyword-reset"]').addClass("hidden"); // 검색어 초기화 버튼 숨김
|
||||
modal.find("#drawer-search-footer").addClass('hidden') //검색풋터(검색버튼 포함) 숨김
|
||||
modal.find('[data-role="none"]').addClass('d-none');
|
||||
if ($(this).val().length >= 2) {
|
||||
modal.find('[data-role="keyword-reset"]').removeClass("hidden");
|
||||
}
|
||||
});
|
||||
|
||||
// 검색어 입력필드 초기화
|
||||
$(document).on('tap click','[data-act="keyword-reset"]',function(){
|
||||
var modal = modal_search
|
||||
modal.find('[name="keyword"]').val('').autocomplete('clear'); // 입력필드 초기화
|
||||
setTimeout(function(){
|
||||
modal.find('[name="keyword"]').focus(); // 입력필드 포커싱
|
||||
modal.find('[data-role="keyword-reset"]').addClass("hidden"); // 검색어 초기화 버튼 숨김
|
||||
modal.find('[data-role="none"]').addClass('d-none');
|
||||
modal.find('[data-role="list-post"]').empty();
|
||||
}, 10);
|
||||
});
|
||||
|
||||
// 검색모달이 닫혔을때
|
||||
modal_search.on('hidden.rc.modal', function () {
|
||||
var modal = $(this)
|
||||
modal.find('[name="keyword"]').autocomplete('clear');
|
||||
$('.autocomplete-suggestions').remove();
|
||||
modal.find('[name="keyword"]').val('');
|
||||
modal.find('[data-role="list-post"]').html('');
|
||||
modal.find('[data-role="keyword-reset"]').addClass("hidden"); // 검색어 초기화 버튼 숨김'
|
||||
})
|
||||
23
modules/search/themes/_mobile/rc-default/component.php
Normal file
23
modules/search/themes/_mobile/rc-default/component.php
Normal file
@@ -0,0 +1,23 @@
|
||||
<!-- 통합검색 -->
|
||||
<div id="modal-search" class="modal fast" data-role="search">
|
||||
<header class="bar bar-nav px-0 bg-white">
|
||||
<a class="icon material-icons pull-left pl-3 pr-2 text-muted" role="button" data-history="back">arrow_back</a>
|
||||
<form class="input-group">
|
||||
<input type="search" name="keyword" class="form-control bg-faded" placeholder="검색어 입력" required autocomplete="off">
|
||||
<span class="input-group-btn hidden" data-role="keyword-reset" >
|
||||
<button class="btn btn-link btn-nav" type="button" data-act="keyword-reset" tabindex="-1">
|
||||
<i class="icon material-icons" aria-hidden="true">close</i>
|
||||
</button>
|
||||
</span>
|
||||
</form>
|
||||
</header>
|
||||
<main class="content bg-white">
|
||||
|
||||
<ul class="table-view table-view-sm mt-2 border-top-0 border-bottom-0" data-role="list-list"></ul>
|
||||
|
||||
<ul class="table-view table-view-sm mt-2 border-top-0 border-bottom-0" data-role="list-post"></ul>
|
||||
|
||||
</main>
|
||||
</div><!-- /.modal -->
|
||||
|
||||
<script src="/modules/search/themes/_mobile/rc-default/component.js<?php echo $g['wcache']?>" ></script>
|
||||
7
modules/search/themes/_mobile/rc-default/main.css
Normal file
7
modules/search/themes/_mobile/rc-default/main.css
Normal file
@@ -0,0 +1,7 @@
|
||||
.bar input[type="search"] {
|
||||
height: 2.35rem;
|
||||
margin: .2rem 0;
|
||||
}
|
||||
.rb-main {
|
||||
margin-top: -1px
|
||||
}
|
||||
190
modules/search/themes/_mobile/rc-default/main.php
Normal file
190
modules/search/themes/_mobile/rc-default/main.php
Normal file
@@ -0,0 +1,190 @@
|
||||
<!-- markjs js : https://github.com/julmot/mark.js -->
|
||||
<?php getImport('markjs','jquery.mark.min','8.11.1','js')?>
|
||||
|
||||
<header class="bar bar-nav bar-dark bg-primary pl-0 pr-1">
|
||||
<form name="RbSearchForm" action="<?php echo $g['s']?>/" class="input-group" role="form" id="search-form" style="top: 0;">
|
||||
<input type="hidden" name="r" value="<?php echo $r?>">
|
||||
<input type="hidden" name="m" value="<?php echo $m?>">
|
||||
<input type="hidden" name="where" value="<?php echo $where?>">
|
||||
<input type="hidden" name="swhere" value="all">
|
||||
<input type="hidden" name="term" value="<?php echo $term?>">
|
||||
<input type="hidden" name="orderby" value="<?php echo $orderby?>">
|
||||
<span class="input-group-btn" data-role="return-result">
|
||||
<a class="icon icon-left-nav pull-left px-2" role="button" href="<?php echo RW(0) ?>"></a>
|
||||
</span>
|
||||
<input type="search" class="form-control border-0" placeholder="검색어를 입력하세요." value="<?php echo $_keyword?>" id="search-input-page" name="keyword" autocomplete="off">
|
||||
<span class="input-group-btn hidden" data-role="reset-keyword">
|
||||
<button class="btn btn-secondary px-3" type="button" data-act="keyword-reset" tabindex="-1">
|
||||
<i class="fa fa-times-circle fa-lg" aria-hidden="true"></i>
|
||||
</button>
|
||||
</span>
|
||||
</form>
|
||||
</header>
|
||||
|
||||
<!-- Block button in standard bar fixed below top bar -->
|
||||
<div class="bar bar-standard bar-header-secondary bar-light bg-white">
|
||||
<nav class="nav nav-inline">
|
||||
<a id="nav_search_all" class="nav-link<?php if($swhere=='all'):?> active<?php endif?>" href="<?php echo $g['url_where'] ?>all" data-control="push" data-transition="fade" data-act="moreResult">전체</a>
|
||||
<a id="nav_site_page" class="nav-link<?php if($swhere=='site_page'):?> active<?php endif?>" href="<?php echo $g['url_where'] ?>site_page" data-control="push" data-transition="fade" data-act="moreResult">페이지</a>
|
||||
<a id="nav_bbs_post" class="nav-link<?php if($swhere=='bbs_post'):?> active<?php endif?>" href="<?php echo $g['url_where'] ?>bbs_post" data-control="push" data-transition="fade" data-act="moreResult">게시물</a>
|
||||
<a id="nav_mediaset_photo" class="nav-link<?php if($swhere=='mediaset_photo'):?> active<?php endif?>" href="<?php echo $g['url_where'] ?>mediaset_photo" data-control="push" data-transition="fade" data-act="moreResult">사진</a>
|
||||
<a id="nav_mediaset_youtube" class="nav-link<?php if($swhere=='mediaset_youtube'):?> active<?php endif?>" href="<?php echo $g['url_where'] ?>mediaset_youtube" data-control="push" data-transition="fade" data-act="moreResult">동영상</a>
|
||||
<a id="nav_mediaset_file" class="nav-link<?php if($swhere=='mediaset_file'):?> active<?php endif?>" href="<?php echo $g['url_where'] ?>mediaset_file" data-control="push" data-transition="fade" data-act="moreResult">파일</a>
|
||||
</nav>
|
||||
</div>
|
||||
<div class="bar bar-standard bar-footer bar-light bg-faded hidden" id="search-footer">
|
||||
<button class="btn btn-secondary btn-block" id="search-form-submit">검색</button>
|
||||
</div>
|
||||
|
||||
<div class="content bg-faded" data-role="panal-result">
|
||||
<main class="rb-main" data-plugin="markjs">
|
||||
|
||||
<?php if($keyword && $swhere == 'all'):?>
|
||||
<div id="rb-sortbar" class="card p-a-1 bg-white">
|
||||
총 <span id="rb_sresult_num_all" class="badge badge-primary badge-outline">0</span> 건이 검색 되었습니다.
|
||||
</div>
|
||||
|
||||
<div id="search_no_result" class="d-none content-padded">
|
||||
<div class="alert alert-info text-xs-center"><strong>‘<span><?php echo $keyword;?></span>’에 대한 검색결과가 없습니다.</strong></div>
|
||||
<ul class="list-unstyled text-muted">
|
||||
<li>검색어의 철자를 정확하게 입력했는지 확인해 보세요.</li>
|
||||
<li>연관된 다른 검색어나 비슷한 의미의 일반적인 단어를 입력하여 찾아 보세요.</li>
|
||||
</ul>
|
||||
<p>
|
||||
<a href="<?php echo RW(0) ?>" class="btn btn-secondary btn-block">홈으로</a>
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<?php endif?>
|
||||
|
||||
|
||||
<?php $_ResultArray['num']=array()?>
|
||||
<?php if($keyword):?>
|
||||
<?php foreach($d['search_order'] as $_key => $_val):if(!strstr($_val[1],'['.$r.']'))continue?>
|
||||
<?php $_iscallpage=($swhere == 'all' || $swhere == $_key)?>
|
||||
<?php if($_iscallpage):?>
|
||||
<?php if(is_file($_val[2].'.css')) echo '<link href="'.$_val[2].'.css" rel="stylesheet">'?>
|
||||
<section id="rb_search_panel_<?php echo $_key?>" class="widget mb-2">
|
||||
<header>
|
||||
<div class="content-padded">
|
||||
<?php echo $_val[0]?>
|
||||
<small class="ml-2"><span id="rb_sresult_num_tt_<?php echo $_key?>" class="text-danger">0</span> 건</small>
|
||||
</div>
|
||||
|
||||
</header>
|
||||
<?php endif?>
|
||||
|
||||
<!-- 검색결과 -->
|
||||
<div class="">
|
||||
<?php include $_val[2].'.php' ?>
|
||||
</div>
|
||||
<!-- @검색결과 -->
|
||||
<?php if($_iscallpage): ?>
|
||||
<?php if($swhere==$_key): ?>
|
||||
<footer>
|
||||
<div class="p-x-0">
|
||||
<?php echo getPageLink_RC(3,$p,getTotalPage($_ResultArray['num'][$_key],$d['search']['num2']),'1')?>
|
||||
</div>
|
||||
</footer>
|
||||
<?php else:?>
|
||||
<?php if($_ResultArray['num'][$_key] > $d['search']['num1']):?>
|
||||
<footer class="p-2 text-xs-right">
|
||||
<a href="<?php echo $g['url_where'].$_key ?>" class="btn btn-link text-muted" data-control="push" data-transition="fade" data-act="moreResult">
|
||||
<?php echo $_val[0]?> 더보기 <i class="fa fa-arrow-circle-o-right fa-lg" aria-hidden="true"></i>
|
||||
</a>
|
||||
</footer>
|
||||
<?php endif ?>
|
||||
<?php endif?>
|
||||
</section>
|
||||
|
||||
<?php endif?>
|
||||
|
||||
<?php endforeach?>
|
||||
|
||||
<?php else:?>
|
||||
<div id="rb-searchresult-none" class="content-padded">
|
||||
<p>검색어를 입력해 주세요.</p>
|
||||
</div>
|
||||
<?php endif?>
|
||||
</main>
|
||||
</div><!-- /.content -->
|
||||
|
||||
<script>
|
||||
|
||||
// 통합검색 입력창
|
||||
var doSearchInput = function(){
|
||||
|
||||
$('#search-input-page').focus(function(){
|
||||
var keyword = $(this).val()
|
||||
var modal = $('#modal-search')
|
||||
$('.loader-overlay').remove()
|
||||
modal.modal('show')
|
||||
setTimeout(function(){
|
||||
$('#search-input').val(keyword).focus()
|
||||
modal.find('[data-role="keyword-reset"]').removeClass('hidden')
|
||||
}, 310);
|
||||
});
|
||||
|
||||
};
|
||||
|
||||
var doSearchResult = function(){
|
||||
|
||||
function searchSortChange(obj)
|
||||
{
|
||||
var f = document.RbSearchForm;
|
||||
f.orderby.value = obj.value;
|
||||
f.submit();
|
||||
}
|
||||
function searchTermChange(obj)
|
||||
{
|
||||
var f = document.RbSearchForm;
|
||||
f.term.value = obj.value;
|
||||
f.submit();
|
||||
}
|
||||
function searchWhereChange(obj)
|
||||
{
|
||||
var f = document.RbSearchForm;
|
||||
f.where.value = obj.value;
|
||||
f.submit();
|
||||
}
|
||||
|
||||
// marks.js
|
||||
$('[data-plugin="markjs"]').mark("<?php echo $keyword ?>");
|
||||
|
||||
<?php $total = 0?>
|
||||
|
||||
<?php foreach($_ResultArray['num'] as $_key => $_val):$total+=$_val?>
|
||||
|
||||
if ($('#rb_sresult_num_tt_<?php echo $_key?>')) {
|
||||
$('#rb_sresult_num_tt_<?php echo $_key?>').text('<?php echo $_val?>')
|
||||
}
|
||||
|
||||
<?php if(!$_val):?>
|
||||
$('#rb_search_panel_<?php echo $_key?>').addClass('d-none')
|
||||
$('#nav_<?php echo $_key?>').addClass('d-none')
|
||||
<?php endif?>
|
||||
|
||||
<?php endforeach?>
|
||||
|
||||
var search_result_total = <?php echo $swhere=='all'?$total:$_ResultArray['num'][$swhere]?>;
|
||||
if(search_result_total==0){
|
||||
$("#search_no_result").removeClass("d-none");
|
||||
$('.bar-header-secondary').remove()
|
||||
}
|
||||
$('#rb_sresult_num_all').text(search_result_total)
|
||||
|
||||
<?php if(!$_ResultArray['spage']):?>
|
||||
if(getId('rb-sortbar')) getId('rb-sortbar').className = 'd-none';
|
||||
<?php endif?>
|
||||
|
||||
};
|
||||
|
||||
$(function () {
|
||||
|
||||
// 검색관련 스크립트 실행
|
||||
doSearchInput();
|
||||
doSearchResult();
|
||||
|
||||
})
|
||||
|
||||
</script>
|
||||
1
modules/search/themes/_mobile/rc-default/name.txt
Normal file
1
modules/search/themes/_mobile/rc-default/name.txt
Normal file
@@ -0,0 +1 @@
|
||||
알씨 기본형
|
||||
1
modules/search/var/names/desktop.bbs-post.txt
Normal file
1
modules/search/var/names/desktop.bbs-post.txt
Normal file
@@ -0,0 +1 @@
|
||||
게시판 검색|[home]
|
||||
1
modules/search/var/names/mobile.bbs-post.txt
Normal file
1
modules/search/var/names/mobile.bbs-post.txt
Normal file
@@ -0,0 +1 @@
|
||||
게시물 검색|[home]
|
||||
5
modules/search/var/search.list.txt
Normal file
5
modules/search/var/search.list.txt
Normal file
@@ -0,0 +1,5 @@
|
||||
GOOGLE,http://www.google.com/search?q=
|
||||
YAHOO,http://kr.search.yahoo.com/search?p=
|
||||
NAVER,http://search.naver.com/search.naver?query=
|
||||
NATE,http://search.nate.com/search/all.html?q=
|
||||
DAUM,http://search.daum.net/search?q=
|
||||
11
modules/search/var/var.moduleinfo.php
Normal file
11
modules/search/var/var.moduleinfo.php
Normal file
@@ -0,0 +1,11 @@
|
||||
<?php
|
||||
/*
|
||||
각각의 링크를 제공하려면 다음과 같은 형식으로 지정해 주세요.
|
||||
이 링크는 관리자모드 모듈정보 링크에 사용됩니다.
|
||||
*/
|
||||
$d['moduleinfo']['market'] = 'http://www.kimsq.co.kr/market'; // 마켓
|
||||
$d['moduleinfo']['github'] = 'https://github.com/kimsQ/rb'; // 저장소
|
||||
$d['moduleinfo']['issue'] = 'https://github.com/kimsQ/rb/issues'; // 이슈접수
|
||||
$d['moduleinfo']['website'] = 'http://www.kimsq.co.kr/'; // 웹사이트
|
||||
$d['moduleinfo']['help'] = 'http://docs.kimsq.com/rb2/docs/c/Users/modules/search'; // 도움말
|
||||
?>
|
||||
11
modules/search/var/var.order.desktop.php
Normal file
11
modules/search/var/var.order.desktop.php
Normal file
@@ -0,0 +1,11 @@
|
||||
<?php
|
||||
$d['search_order']['post_data'] = array('포스트','[home]','./modules/post/for-searching/_desktop/data');
|
||||
$d['search_order']['post_list'] = array('리스트','[home]','./modules/post/for-searching/_desktop/list');
|
||||
$d['search_order']['bbs_post'] = array('게시판','[home]','./modules/bbs/for-searching/_desktop/post');
|
||||
$d['search_order']['comment_data'] = array('댓글','[home]','./modules/comment/for-searching/_desktop/search');
|
||||
$d['search_order']['member'] = array('인물','[home]','./modules/member/for-searching/_desktop/search');
|
||||
$d['search_order']['mediaset_photo'] = array('이미지','[home]','./modules/mediaset/for-searching/_desktop/photo');
|
||||
$d['search_order']['mediaset_video'] = array('동영상','[home]','./modules/mediaset/for-searching/_desktop/video');
|
||||
$d['search_order']['mediaset_file'] = array('첨부파일','[home]','./modules/mediaset/for-searching/_desktop/file');
|
||||
$d['search_order']['site_page'] = array('페이지','[home]','./modules/site/for-searching/_desktop/page');
|
||||
?>
|
||||
3
modules/search/var/var.order.mobile.php
Normal file
3
modules/search/var/var.order.mobile.php
Normal file
@@ -0,0 +1,3 @@
|
||||
<?php
|
||||
$d['search_order']['bbs_post'] = array('게시판','[home]','./modules/bbs/for-searching/_mobile/post');
|
||||
?>
|
||||
9
modules/search/var/var.search.php
Normal file
9
modules/search/var/var.search.php
Normal file
@@ -0,0 +1,9 @@
|
||||
<?php
|
||||
$d['search']['theme'] = "_desktop/bs4-default";
|
||||
$d['search']['m_theme'] = "_mobile/rc-default";
|
||||
$d['search']['num1'] = "5";
|
||||
$d['search']['num2'] = "20";
|
||||
$d['search']['term'] = "12";
|
||||
$d['search']['layout'] = "bs4-default/blank.php";
|
||||
$d['search']['m_layout'] = "rc-starter/blank.php";
|
||||
?>
|
||||
Reference in New Issue
Block a user