리빌더 부분 추가
This commit is contained in:
138
theme/rb.basic/mobile/skin/faq/basic/list.skin.php
Normal file
138
theme/rb.basic/mobile/skin/faq/basic/list.skin.php
Normal file
@ -0,0 +1,138 @@
|
||||
<?php
|
||||
if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
|
||||
|
||||
// add_stylesheet('css 구문', 출력순서); 숫자가 작을 수록 먼저 출력됨
|
||||
add_stylesheet('<link rel="stylesheet" href="'.$faq_skin_url.'/style.css">', 0);
|
||||
?>
|
||||
|
||||
<!-- FAQ 시작 { -->
|
||||
<?php
|
||||
// 상단 HTML
|
||||
echo '<div id="faq_hhtml">'.conv_content($fm['fm_mobile_head_html'], 1).'</div>';
|
||||
?>
|
||||
|
||||
<?php
|
||||
if( count($faq_master_list) ){
|
||||
?>
|
||||
|
||||
<div id="faq_sch">
|
||||
<form name="faq_search_form" method="get">
|
||||
<input type="hidden" name="fm_id" value="<?php echo $fm_id;?>">
|
||||
<label for="stx" class="sound_only">검색어<strong class="sound_only"> 필수</strong></label>
|
||||
<input type="text" name="stx" value="<?php echo $stx;?>" required id="stx" class="frm_input" size="15" maxlength="15">
|
||||
<button type="submit" value="검색" class="btn_submit"><i class="fa fa-search" aria-hidden="true"></i><span class="sound_only">검색</span></button>
|
||||
</form>
|
||||
</div>
|
||||
|
||||
<nav id="bo_cate">
|
||||
<h2>자주하시는질문 분류</h2>
|
||||
<ul id="bo_cate_ul">
|
||||
<?php
|
||||
foreach( $faq_master_list as $v ){
|
||||
$category_msg = '';
|
||||
$category_option = '';
|
||||
if($v['fm_id'] == $fm_id){ // 현재 선택된 카테고리라면
|
||||
$category_option = ' id="bo_cate_on"';
|
||||
$category_msg = '<span class="sound_only">열린 분류 </span>';
|
||||
}
|
||||
?>
|
||||
<li><a href="<?php echo $category_href;?>?fm_id=<?php echo $v['fm_id']?>" <?php echo $category_option;?> ><?php echo $category_msg.$v['fm_subject'];?></a></li>
|
||||
<?php
|
||||
}
|
||||
?>
|
||||
</ul>
|
||||
</nav>
|
||||
<?php } ?>
|
||||
|
||||
<div id="faq_wrap" class="faq_<?php echo $fm_id; ?>">
|
||||
<?php // FAQ 내용
|
||||
if( count($faq_list) ){
|
||||
?>
|
||||
<section id="faq_con">
|
||||
<h2><?php echo $g5['title']; ?> 목록</h2>
|
||||
<ol>
|
||||
<?php
|
||||
foreach($faq_list as $key=>$v){
|
||||
if(empty($v))
|
||||
continue;
|
||||
?>
|
||||
<li>
|
||||
<h3>
|
||||
<span class="tit_bg">Q</span><a href="#none" onclick="return faq_open(this);"><?php echo conv_content($v['fa_subject'], 1); ?></a>
|
||||
<button class="tit_btn" onclick="return faq_open(this);"><i class="fa fa-plus" aria-hidden="true"></i><span class="sound_only">열기</span></button>
|
||||
</h3>
|
||||
<div class="con_inner">
|
||||
<?php echo conv_content($v['fa_content'], 1); ?>
|
||||
<button type="button" class="closer_btn"><i class="fa fa-minus" aria-hidden="true"></i><span class="sound_only">닫기</span></button>
|
||||
</div>
|
||||
</li>
|
||||
<?php
|
||||
}
|
||||
?>
|
||||
</ol>
|
||||
</section>
|
||||
<?php
|
||||
|
||||
} else {
|
||||
if($stx){
|
||||
echo '<p class="empty_list">검색된 게시물이 없습니다.</p>';
|
||||
} else {
|
||||
echo '<div class="empty_table">등록된 FAQ가 없습니다.';
|
||||
if($is_admin)
|
||||
echo '<br><a href="'.G5_ADMIN_URL.'/faqmasterlist.php">FAQ를 새로 등록하시려면 FAQ관리</a> 메뉴를 이용하십시오.';
|
||||
echo '</div>';
|
||||
}
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
|
||||
<?php echo get_paging($page_rows, $page, $total_page, $_SERVER['SCRIPT_NAME'].'?'.$qstr.'&page='); ?>
|
||||
|
||||
<?php
|
||||
// 하단 HTML
|
||||
echo '<div id="faq_thtml">'.conv_content($fm['fm_mobile_tail_html'], 1).'</div>';
|
||||
?>
|
||||
|
||||
|
||||
<!-- } FAQ 끝 -->
|
||||
|
||||
<script src="<?php echo G5_JS_URL; ?>/viewimageresize.js"></script>
|
||||
<script>
|
||||
jQuery(function() {
|
||||
$(".closer_btn").on("click", function() {
|
||||
$(this).closest(".con_inner").slideToggle('slow', function() {
|
||||
var $h3 = $(this).closest("li").find("h3");
|
||||
|
||||
$("#faq_con li h3").removeClass("faq_li_open");
|
||||
if($(this).is(":visible")) {
|
||||
$h3.addClass("faq_li_open");
|
||||
}
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
function faq_open(el)
|
||||
{
|
||||
var $con = $(el).closest("li").find(".con_inner"),
|
||||
$h3 = $(el).closest("li").find("h3");
|
||||
|
||||
if($con.is(":visible")) {
|
||||
$con.slideUp();
|
||||
$h3.removeClass("faq_li_open");
|
||||
} else {
|
||||
$("#faq_con .con_inner:visible").css("display", "none");
|
||||
|
||||
$con.slideDown(
|
||||
function() {
|
||||
// 이미지 리사이즈
|
||||
$con.viewimageresize2();
|
||||
$("#faq_con li h3").removeClass("faq_li_open");
|
||||
|
||||
$h3.addClass("faq_li_open");
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
</script>
|
||||
28
theme/rb.basic/mobile/skin/faq/basic/style.css
Normal file
28
theme/rb.basic/mobile/skin/faq/basic/style.css
Normal file
@ -0,0 +1,28 @@
|
||||
@charset "utf-8";
|
||||
|
||||
#bo_cate h2 {width:0;height:0;font-size:0;line-height:0;overflow:hidden}
|
||||
#bo_cate ul {background:#fff;padding-left:1px;border-bottom:1px solid #d9dce3;zoom:1}
|
||||
#bo_cate ul:after {display:block;visibility:hidden;clear:both;content:""}
|
||||
#bo_cate li {display:inline-block;float:left;}
|
||||
#bo_cate a {display:block;line-height:24px;padding:15px;border-radius:13px;background:#fff}
|
||||
#bo_cate #bo_cate_on {display:inline-block;position:relative;color:#3a8afd}
|
||||
#bo_cate #bo_cate_on:after {content:"";position:absolute;left:0;bottom:0;width:100%;height:4px;display:inline-block;background:#3a8afd}
|
||||
|
||||
#faq_wrap {margin:0 0 30px}
|
||||
#faq_wrap h2 {position:absolute;font-size:0;line-height:0;overflow:hidden}
|
||||
.faq_admin {text-align:right}
|
||||
#faq_wrap ol {margin:0;padding:0;list-style:none}
|
||||
#faq_wrap li {border-bottom:1px solid #ececec;background:#fff;position:relative}
|
||||
#faq_wrap li h3 {min-height:50px;line-height:30px;padding:15px;padding-left:50px;position:relative}
|
||||
#faq_wrap li h3 a {font-size:1.2em}
|
||||
#faq_wrap li h3 .tit_btn {position:absolute;right:15px;top:15px;border:0;width:30px;height:30px;background:#fff;color:#c5cdd8;font-size:1.2em}
|
||||
#faq_wrap li h3 .tit_bg {display:inline-block;position:absolute;top:15px;left:15px;text-align:center;color:#000;font-size:1.6em}
|
||||
#faq_wrap li h3.faq_li_open a {color:#3a8afd}
|
||||
|
||||
#faq_con .con_inner {display:none;padding:5px 5px 20px 50px}
|
||||
#faq_con .con_inner .tit_bg {display:inline-block;position:absolute;top:10px;left:10px;text-align:center;background:#777;color:#fff;border-radius:50%;width:30px;line-height:30px;height:30px}
|
||||
#faq_con .con_inner .closer_btn {position:absolute;right:15px;top:15px;border:0;width:30px;height:30px;background:#fff;color:#3a8afd;font-size:1.2em}
|
||||
|
||||
#faq_sch {position:relative;padding:15px;text-align:center}
|
||||
#faq_sch .frm_input {width:100%;height:45px;border:2px solid #3a8afd;border-radius:0}
|
||||
#faq_sch .btn_submit {position:absolute;top:17px;right:17px;width:41px;height:41px;background:none;color:#000;font-size:15px}
|
||||
Reference in New Issue
Block a user