5.4 버전 내용 적용

This commit is contained in:
thisgun
2019-12-02 10:22:12 +09:00
parent b60daff8f0
commit 22aad37bfb
534 changed files with 19867 additions and 17830 deletions

View File

@ -5,24 +5,33 @@ if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가
add_stylesheet('<link rel="stylesheet" href="'.$poll_skin_url.'/style.css">', 0);
?>
<!-- 설문조사 시작 { -->
<form name="fpoll" action="<?php echo G5_BBS_URL ?>/poll_update.php" onsubmit="return fpoll_submit(this);" method="post">
<input type="hidden" name="po_id" value="<?php echo $po_id ?>">
<input type="hidden" name="skin_dir" value="<?php echo urlencode($skin_dir); ?>">
<aside id="poll">
<header>
<h2><i class="fa fa-bar-chart" aria-hidden="true"></i> 설문조사</h2>
<?php if ($is_admin == "super") { ?><a href="<?php echo G5_ADMIN_URL ?>/poll_form.php?w=u&amp;po_id=<?php echo $po_id ?>" class="btn_admin">설문조사 관리</a><?php } ?>
<p><?php echo $po['po_subject'] ?></p>
<h2>설문조사</h2>
<a href="<?php echo G5_BBS_URL."/poll_result.php?po_id=$po_id&amp;skin_dir=".urlencode($skin_dir); ?>" target="_blank" onclick="poll_result(this.href); return false;" class="btn_result">결과보기</a>
<?php if ($is_admin == "super") { ?><a href="<?php echo G5_ADMIN_URL ?>/poll_form.php?w=u&amp;po_id=<?php echo $po_id ?>" class="btn_admin btn"><i class="fa fa-cog fa-spin fa-fw"></i><span class="sound_only">관리자 관리</span></a><?php } ?>
</header>
<ul>
<?php for ($i=1; $i<=9 && $po["po_poll{$i}"]; $i++) { ?>
<li><input type="radio" name="gb_poll" value="<?php echo $i ?>" id="gb_poll_<?php echo $i ?>"> <label for="gb_poll_<?php echo $i ?>"><?php echo $po['po_poll'.$i] ?></label></li>
<?php } ?>
</ul>
<footer>
<input type="submit" value="투표하기" class="btn btn_b02">
<a href="<?php echo G5_BBS_URL."/poll_result.php?po_id=$po_id&amp;skin_dir=".urlencode($skin_dir); ?>" target="_blank" onclick="poll_result(this.href); return false;" class="btn btn_b01">결과보기</a>
</footer>
<div class="poll_con">
<p><?php echo $po['po_subject'] ?></p>
<ul>
<?php for ($i=1; $i<=9 && $po["po_poll{$i}"]; $i++) { ?>
<li class="chk_box">
<input type="radio" name="gb_poll" value="<?php echo $i ?>" id="gb_poll_<?php echo $i ?>">
<label for="gb_poll_<?php echo $i ?>">
<span></span>
<?php echo $po['po_poll'.$i] ?>
</label>
</li>
<?php } ?>
</ul>
<div id="poll_btn">
<button type="submit" class="btn_poll">투표하기</button>
</div>
</div>
</aside>
</form>
@ -62,4 +71,5 @@ function poll_result(url)
win_poll(url);
}
</script>
</script>
<!-- } 설문조사 끝 -->

View File

@ -1,29 +1,48 @@
<?php
if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가
$get_max_cnt = 0;
if ((int) $total_po_cnt > 0){
foreach( $list as $k => $v ) {
$get_max_cnt = max( array( $get_max_cnt, $v['cnt'] ) ); // 가장 높은 투표수를 뽑습니다.
}
}
// add_stylesheet('css 구문', 출력순서); 숫자가 작을 수록 먼저 출력됨
add_stylesheet('<link rel="stylesheet" href="'.$poll_skin_url.'/style.css">', 0);
?>
<!-- 설문조사 결과 시작 { -->
<div id="poll_result" class="new_win">
<h1 id="win_title"><?php echo $g5['title'] ?></h1>
<div class="new_win_con">
<div class="new_win_con2">
<!-- 설문조사 결과 그래프 시작 { -->
<span class="poll_all">전체 <?php echo $nf_total_po_cnt ?>표</span>
<section id="poll_result_list">
<h2><?php echo $po_subject ?> 결과</h2>
<ol>
<?php for ($i=1; $i<=count($list); $i++) { ?>
<li>
<span><?php echo $list[$i]['content'] ?></span>
<span class="poll_percent"><?php echo number_format($list[$i]['rate'], 1) ?> %</span>
<?php
for ($i=1; $i<=count($list); $i++) {
// 가장 높은 투표수와 같으면 li 태그에 poll_1st 클래스가 붙습니다.
$poll_1st_class = ($get_max_cnt && ((int) $list[$i]['cnt'] === (int) $get_max_cnt)) ? 'poll_1st' : '';
?>
<li class="<?php echo $poll_1st_class; ?>">
<span><?php echo $list[$i]['content'] ?></span>
<div class="poll_result_graph">
<span style="width:<?php echo number_format($list[$i]['rate'], 1) ?>%"><strong class="poll_cnt"><?php echo $list[$i]['cnt'] ?> 표</strong></span>
<span style="width:<?php echo number_format($list[$i]['rate'], 1) ?>%"></span>
</div>
<div class="poll_numerical">
<strong class="poll_cnt"><?php echo $list[$i]['cnt'] ?> 표</strong>
<span class="poll_percent"><?php echo number_format($list[$i]['rate'], 1) ?> %</span>
</div>
</li>
<?php } ?>
<?php } ?>
</ol>
</section>
<!-- } 설문조사 결과 그래프 끝 -->
<!-- 설문조사 기타의견 시작 { -->
<?php if ($is_etc) { ?>
<section id="poll_result_cmt">
<h2>이 설문에 대한 기타의견</h2>
@ -35,53 +54,43 @@ add_stylesheet('<link rel="stylesheet" href="'.$poll_skin_url.'/style.css">', 0)
<?php echo $list2[$i]['name'] ?>
<span class="poll_datetime"><?php echo $list2[$i]['datetime'] ?>
<span class="poll_cmt_del"><?php if ($list2[$i]['del']) { echo $list2[$i]['del']."<i class=\"fa fa-times-circle\" aria-hidden=\"true\"></i><span class=\"sound_only\">삭제</span></a>"; } ?></span></span>
</header>
<p>
<?php echo $list2[$i]['idea'] ?>
</p>
</p>
</article>
<?php } ?>
<?php if ($member['mb_level'] >= $po['po_level']) { ?>
<form name="fpollresult" method="post" action="./poll_etc_update.php" onsubmit="return fpollresult_submit(this);" autocomplete="off">
<?php if ($member['mb_level'] >= $po['po_level']) { ?>
<form name="fpollresult" action="./poll_etc_update.php" onsubmit="return fpollresult_submit(this);" method="post" autocomplete="off" id="poll_other_q">
<input type="hidden" name="po_id" value="<?php echo $po_id ?>">
<input type="hidden" name="w" value="">
<input type="hidden" name="skin_dir" value="<?php echo urlencode($skin_dir); ?>">
<?php if ($is_member) { ?><input type="hidden" name="pc_name" value="<?php echo get_text(cut_str($member['mb_nick'],255)); ?>"><?php } ?>
<h3><?php echo $po_etc ?></h3>
<div class="tbl_frm01 tbl_wrap">
<table id="poll_result_wcmt">
<tbody>
<?php if ($is_guest) { ?>
<tr>
<td><input type="text" name="pc_name" id="pc_name" class="frm_input full_input required" required placeholder="이름(필수)"></td>
</tr>
<?php } ?>
<tr>
<td><input type="text" name="pc_idea" id="pc_idea" class="frm_input full_input required" required maxlength="100" placeholder="의견(필수)"></td>
</tr>
<?php if ($is_guest) { ?>
<tr>
<td><?php echo captcha_html(); ?></td>
</tr>
<?php } ?>
</tbody>
</table>
<?php if ($is_member) { ?><input type="hidden" name="pc_name" value="<?php echo get_text(cut_str($member['mb_nick'],255)) ?>"><?php } ?>
<div id="poll_result_wcmt">
<h3><span>기타의견</span><?php echo $po_etc ?></h3>
<div>
<label for="pc_idea" class="sound_only">의견<strong>필수</strong></label>
<input type="text" id="pc_idea" name="pc_idea" required class="full_input required" size="47" maxlength="100" placeholder="의견을 입력해주세요">
</div>
</div>
<div class="btn_confirm">
<input type="submit" class="btn_submit" value="의견남기기">
<?php if ($is_guest) { ?>
<div class="poll_guest">
<label for="pc_name" class="sound_only">이름<strong>필수</strong></label>
<input type="text" name="pc_name" id="pc_name" required class="full_input required" size="20" placeholder="이름">
</div>
<?php } ?>
<?php echo captcha_html(); ?>
<button type="submit" class="btn_submit">의견남기기</button>
</form>
<?php } ?>
<?php } ?>
</section>
<?php } ?>
<aside id="poll_result_oth" class="list_01">
<!-- } 설문조사 기타의견 끝 -->
<!-- 설문조사 다른 결과 보기 시작 { -->
<aside id="poll_result_oth">
<h2>다른 투표 결과 보기</h2>
<ul>
<?php for ($i=0; $i<count($list3); $i++) { ?>
@ -89,7 +98,8 @@ add_stylesheet('<link rel="stylesheet" href="'.$poll_skin_url.'/style.css">', 0)
<?php } ?>
</ul>
</aside>
<!-- } 설문조사 다른 결과 보기 끝 -->
<div class="win_btn">
<button type="button" onclick="window.close();" class="btn_close">창닫기</button>
</div>
@ -110,4 +120,5 @@ function fpollresult_submit(f)
return true;
}
</script>
</script>
<!-- } 설문조사 결과 끝 -->

View File

@ -1,8 +1,6 @@
@charset "utf-8";
/* SIR 지운아빠 */
/* ### 기본 스타일 커스터마이징 시작 ### */
#poll a.btn_admin {} /* 관리자 전용 버튼 */
#poll a.btn_admin:focus, #poll a.btn_admin:hover {}
@ -18,10 +16,6 @@
#poll .tbl_frm01 td {}
#poll .tbl_frm01 textarea, #poll .frm_input {}
#poll .tbl_frm01 textarea {}
/*
#poll .tbl_frm01 #captcha {}
#poll .tbl_frm01 #captcha input {}
*/
#poll .tbl_frm01 a {}
#poll .required, #poll textarea.required {}
@ -38,66 +32,76 @@
/* ### 기본 스타일 커스터마이징 끝 ### */
/* 설문조사 스킨 */
#poll {margin:30px 10px }
#poll header {position:relative;}
#poll h2 {display:inline-block;background: #4162ff;color: #fff;border-radius: 13px;line-height: 24px;padding: 0 10px;margin:0 0 10px;
-webkit-box-shadow: 0 0 5px rgba(65,98,255,0.8);
-moz-box-shadow: 0 0 5px rgba(65,98,255,0.8);
box-shadow: 0 0 8px rgba(65,98,255,0.8);
}
#poll header .btn_admin {display:block;margin:0 0 5px;color:#fff;text-align:center;text-decoration:none;line-height:2em;vertical-align:middle}
#poll header p {padding:0;font-weight:bold}
#poll li {background:#fff;margin: 8px 0;padding:10px;
-webkit-box-shadow: 0 1px 4px #cbd1df;
-moz-box-shadow: 0 1px 4px #cbd1df;
box-shadow: 0 1px 4px #cbd1df;}
#poll footer:after {display:block;visibility:hidden;clear:both;content:""}
#poll footer input {float:right;font-weight:bold;}
#poll footer a {display:inline-block;float:left;background:#c6c6d2;color:#333;font-weight:bold}
#poll footer a:focus, #poll footer a:hover {text-decoration:none !important}
#poll {background:#fff;border:1px solid #dde7e9;margin:15px 10px}
#poll header {position:relative;padding:15px;border-bottom:1px solid #dde7e9}
#poll header:after {display:block;visibility:hidden;clear:both;content:""}
#poll header h2 {display:inline-block;float:left;line-height:24px;font-size:1.2em}
#poll header h2:after {display:block;visibility:hidden;clear:both;content:""}
#poll header .btn_result {float:right;display:inline-block;line-height:20px;height:28px;border:1px solid #d5d9dd;color:#3a8afd;border-radius:2px;padding:2px 5px;background:#fff}
#poll header .btn_admin {float:right;height:28px;margin-right:5px;line-height:28px;font-size:1.4em}
#poll ul {padding:10px 20px}
#poll li {padding:5px 0}
.selec_chk {position:absolute;top:0;left:0;width:0;height:0;opacity:0;outline:0;z-index:-1;overflow:hidden}
.chk_box {position:relative}
.chk_box input[type="radio"] {position:absolute;top:0;left:0;width:0;height:0;opacity:0;outline:0;z-index:-1;overflow:hidden}
.chk_box input[type="radio"] + label {position:relative;padding-left:23px;display:inline-block;color:#676e70}
.chk_box input[type="radio"] + label span {position:absolute;top:0;left:0;width:15px;height:15px;display:block;background:#f7f8f9;border:1px solid #cdd6df;border-radius:50%}
.chk_box input[type="radio"]:checked + label {color:#3a8afd}
.chk_box input[type="radio"]:checked + label span {border-color:#3a8afd}
.chk_box input[type="radio"]:checked + label span:before {width:7px;height:7px;background:#3a8afd;content:'';position:absolute;top:3px;left:3px;border-radius:50%}
#poll .poll_con {}
#poll .poll_con p {font-weight:bold;padding:20px 20px 5px;color:#000;font-size:1.167em}
#poll_btn {padding:0 20px 20px;text-align:center}
#poll_btn:after {display:block;visibility:hidden;clear:both;content:""}
#poll_btn .btn_poll {display:block;width:100%;height:40px;line-height:40px;padding:0 10px;border:0;font-weight:bold;background:#3a8afd;color:#fff;border-radius:3px}
/* 설문조사 결과 (새창) */
#poll_result {}
#poll_result section {margin:0 0 20px;padding:25px;border:1px solid #dbdbdb;background:#fff;
-webkit-box-shadow: 0 0 5px rgba(55,55,5,0.1));
-moz-box-shadow: 0 0 5px rgba(55,55,5,0.1));
box-shadow: 0 0 5px rgba(55,55,5,0.1); }
#poll_result {background:#fff}
#poll_result section {}
#poll_result .tbl_wrap {margin:0}
#poll_result h2 {}
#poll_result a {}
#poll_result .sv_member,
#poll_result .sv_guest {font-weight:bold}
#poll_result .poll_all{float:right;display:inline-block;padding:0 5px;margin:0 0 10px;line-height:26px;border:1px solid #ddd;border-radius:3px;font-size:0.92em;background:#fff}
#poll_result .btn_confirm{text-align:right;margin:5px 0 0}
#poll_result_list {margin:0 auto 20px;clear:both}
#poll_result_list h2 {margin:0;font-size:1.083em;padding: 0 0 15px;margin:0 0 15px;border-bottom:1px solid #ddd;text-align:center;}
#poll_result .poll_all {position:absolute;top:10px;right:10px;display:inline-block;margin:0 0 10px;line-height:30px;font-size:0.92em;color:#3a8afd;background:#f6f6f6;padding:0 10px;border-radius:5px}
#poll_result_list {clear:both;margin:20px;border:1px solid #d6e2f4;border-top:0;background:#fff;border-radius:5px}
#poll_result_list h2 {margin:0;font-size:1.25em;padding:15px;margin:0 0 15px;border-top:1px solid #d6e2f4;border-bottom:1px solid #d6e2f4;text-align:center;background:#edf3fc;color:#375582;border-radius:5px}
#poll_result_list dt {margin-right:5%;color:#e8180d;text-align:right}
#poll_result_list ol {margin:0;padding:0}
#poll_result_list ol {margin:0;padding:0 20px}
#poll_result_list li {margin:20px 0;position:relative;list-style-position:inside}
#poll_result_list .poll_percent{position:absolute;top:0;right:0;color:#415b72;font-weight:bold}
.poll_result_graph {position:relative;margin-right:5%;margin:5px 0 ;height:15px;background:#f4f4f4;border-radius:10px 10px}
.poll_result_graph span {position:absolute;top:0;left:0;height:15px;background:#ae99da;border-radius:10px 10px}
.poll_result_graph span .poll_cnt {display:none;position:absolute;top:18px;right:0;font-size:0.92em;text-align:right;background:#333;color:#fff;padding:0 7px;line-height:22px;border-radius:3px}
.poll_result_graph span:hover .poll_cnt {display:block;white-space: nowrap;}
.poll_result_graph span .poll_cnt:before{content: "";position: absolute;top: -6px;left: 50%;margin-left:-4px;width: 0;height: 0;border-style: solid;border-width: 0 4px 6px 4px;border-color: transparent transparent #333 transparent;}
#poll_result_cmt {}
#poll_result_cmt h2 {;font-size:1.083em;}
#poll_result_cmt h3 {margin:0;font-size:1.083em;padding: 0 0 15px;margin:0 0 15px;border-bottom:1px solid #ddd;text-align:center;}
#poll_result_cmt article {margin:15px 0 ;position:relative;}
#poll_result_cmt h2 {position:absolute;margin:0;padding:0;border:0;font-size:0;text-indent:-9999em;line-height:0;overflow:hidden}
#poll_result_cmt header{margin:0 0 5px}
#poll_result_cmt .poll_datetime{display:inline-block;position:absolute;top:0;right:0;font-size:0.92em;color:#777;font-style:italic}
#poll_result_cmt .profile_img img{border-radius:50%}
#poll_result_cmt p {padding:10px;background:#f6f6f6;border-radius:5px;}
#poll_result_cmt fieldset {margin-bottom:0;text-align:left}
#poll_result_cmt fieldset p {margin:0 0 15px;padding:3px 0 0px;text-align:left}
#poll_result_cmt footer {text-align:right}
#poll_result_cmt .btn_submit {height:40px;padding:0 20px}
.poll_cmt_del a {display:inline-block;margin-left:5px;color:#49857c;font-size:16px;}
.poll_cmt_del a:hover{color:#98ca69}
#poll_result_oth {padding:0}
#poll_result_oth ul {margin:0;padding:0;list-style:none;}
#poll_result_oth li{position:relative}
#poll_result_oth li:after {display:block;visibility:hidden;clear:both;content:""}
#poll_result_oth li span{float:right;color:#777;font-size:0.92em;font-style:italic}
.poll_1st .poll_result_graph span {background:#3a8afd}
.poll_result_graph {position:relative;width:80%;margin:5px 0;height:15px;background:#fff;border-radius:10px;-moz-box-shadow:inset 0px 2px 8px #dadada;-webkit-box-shadow:inset 0px 2px 8px #dadada;box-shadow:inset 0px 2px 8px #dadada}
.poll_result_graph span {position:absolute;top:0;left:0;height:15px;background:#8395b3;border-radius:10px 10px;white-space:nowrap}
.poll_numerical {display:inline-block;position:absolute;top:0;right:0;text-align:center}
.poll_numerical .poll_percent {display:block;font-size:1.2em;color:#3a8afd;font-weight:bold;letter-spacing:-0.5px}
.poll_numerical .poll_cnt {font-size:1em;text-align:right;color:#8d8d8d}
#poll_result_cmt {margin:20px}
#poll_result_cmt h2 {position:absolute;font-size:0;line-height:0;overflow:hidden}
#poll_result_cmt article {margin:15px 0;position:relative;border-bottom:1px solid #eaeaea}
#poll_result_cmt h1 {position:absolute;margin:0;padding:0;border:0;font-size:0;text-indent:-9999em;line-height:0;overflow:hidden}
#poll_result_cmt header {margin:0 0 5px}
#poll_result_cmt .poll_datetime {display:inline-block;font-size:0.92em;color:#777}
#poll_result_cmt .profile_img img {border-radius:50%}
#poll_result_cmt p {padding:10px;line-height:1.5em}
#poll_other_q h3 {margin:0;font-size:1.25em;padding:10px;border-bottom:1px solid #eaeaea;text-align:left}
#poll_other_q h3 span {background:#f7f8e3;color:#c97600;padding:3px;display:inline-block;border-radius:5px;margin-right:5px;font-weight:normal;font-size:0.8em}
#poll_result_wcmt {border:1px solid #cfd4db;margin-bottom:10px}
#poll_result_wcmt input {border:0;height:80px;padding:10px}
#poll_result_cmt .btn_submit {padding:0 20px;float:right}
.poll_guest input {border-radius:0;border:1px solid #cfd4db;padding:10px;margin-bottom:10px;display:inline-block}
.poll_cmt_del {float:right}
.poll_cmt_del a {display:inline-block;margin:0 0 5px 10px;color:#c7c9cb;font-size:15px}
.poll_cmt_del:hover a {color:#3a8afd}
#poll_result_oth {clear:both;margin:20px}
#poll_result_oth h2 {padding:0 0 10px}
#poll_result_oth ul {margin:0;padding:0;list-style:none;border:1px solid #ddd;background:#fff;border-top:0}
#poll_result_oth ul li{border-top:1px solid #eaeaea;position:relative;line-height:20px}
#poll_result_oth a {display:block;padding:10px}
#poll_result_oth li span {position:absolute;bottom:10px;right:15px;color:#777;font-size:0.92em}