Compare commits

...
12 Commits
26 changed files with 72 additions and 64 deletions
+1 -1
View File
@@ -2,7 +2,7 @@
$sub_menu = '100310';
include_once('./_common.php');
$nw_id = isset($_POST['nw_id']) ? preg_replace('/[^0-9]/', '', $_POST['nw_id']) : 0;
$nw_id = isset($_REQUEST['nw_id']) ? preg_replace('/[^0-9]/', '', $_REQUEST['nw_id']) : 0;
if ($w == "u" || $w == "d")
check_demo();
+1 -1
View File
@@ -136,7 +136,7 @@ function grouplist_submit(f)
</td>
<td class="td_left">
<label for="fg_name_<?php echo $i; ?>" class="sound_only">그룹명</label>
<input type="text" name="fg_name[<?php echo $i; ?>]" value="<?php echo $group[$i]['fg_name']?>" id="fg_name_<?php echo $i; ?>" class="frm_input">
<input type="text" name="fg_name[<?php echo $i; ?>]" value="<?php echo get_sanitize_input($group[$i]['fg_name']); ?>" id="fg_name_<?php echo $i; ?>" class="frm_input">
<input type="checkbox" name="fg_member[<?php echo $i; ?>]" value="1" id="fg_member_<?php echo $i; ?>" <?php if ($group[$i]['fg_member']) echo 'checked';?>>
<label for="fg_member_<?php echo $i; ?>">회원</label>
</td>
+3 -3
View File
@@ -13,7 +13,7 @@ if ($w == 'u') // 업데이트
// 실제 번호를 넘김
$k = $post_cnk[$i];
$fg_no = isset($_POST['fg_no'][$k]) ? (int) $_POST['fg_no'][$k] : 0;
$fg_name = isset($_POST['fg_name'][$k]) ? addslashes(strip_tags($_POST['fg_name'][$k])) : '';
$fg_name = isset($_POST['fg_name'][$k]) ? addslashes(strip_tags(clean_xss_attributes($_POST['fg_name'][$k]))) : '';
$fg_member = isset($_POST['fg_member'][$k]) ? addslashes(strip_tags($_POST['fg_member'][$k])) : '';
if (!is_numeric($fg_no))
@@ -82,11 +82,11 @@ else if ($w == 'no')
}
else // 등록
{
$fg_name = isset($_POST['fg_name']) ? addslashes(strip_tags(clean_xss_attributes($_POST['fg_name']))) : '';
if (!strlen(trim($fg_name)))
alert('그룹명을 입력해주세요');
$fg_name = addslashes(strip_tags($fg_name));
$res = sql_fetch("select fg_name from {$g5['sms5_form_group_table']} where fg_name = '$fg_name'");
if ($res)
alert('같은 그룹명이 존재합니다.');
+11
View File
@@ -21,6 +21,17 @@ $total_page = ceil($total_count / $rows); // 전체 페이지 계산
if ($page < 1) { $page = 1; } // 페이지가 없으면 첫 페이지 (1 페이지)
$from_record = ($page - 1) * $rows; // 시작 열을 구함
$sql = " select *
{$sql_common}
{$sql_order}
limit {$from_record}, {$rows} ";
$result = sql_query($sql);
for ($i=0; $row=sql_fetch_array($result); $i++) {
$list[] = $row;
}
include_once($member_skin_path.'/point.skin.php');
include_once(G5_PATH.'/tail.sub.php');
+1 -1
View File
@@ -5,7 +5,7 @@
********************/
define('G5_VERSION', '그누보드5');
define('G5_GNUBOARD_VER', '5.4.4.5');
define('G5_GNUBOARD_VER', '5.4.4.7.1');
// 이 상수가 정의되지 않으면 각각의 개별 페이지는 별도로 실행될 수 없음
define('_GNUBOARD_', true);
+5 -4
View File
@@ -2044,17 +2044,18 @@ function bad_tag_convert($code)
global $view;
global $member, $is_admin;
if ($is_admin && $member['mb_id'] != $view['mb_id']) {
if ($is_admin && $member['mb_id'] !== $view['mb_id']) {
//$code = preg_replace_callback("#(\<(embed|object)[^\>]*)\>(\<\/(embed|object)\>)?#i",
// embed 또는 object 태그를 막지 않는 경우 필터링이 되도록 수정
$code = preg_replace_callback("#(\<(embed|object)[^\>]*)\>?(\<\/(embed|object)\>)?#i",
create_function('$matches', 'return "<div class=\"embedx\">보안문제로 인하여 관리자 아이디로는 embed 또는 object 태그를 볼 수 없습니다. 확인하시려면 관리권한이 없는 다른 아이디로 접속하세요.</div>";'),
$code);
$code = preg_replace_callback("#(\<(embed|object)[^\>]*)\>?(\<\/(embed|object)\>)?#i", '_callback_bad_tag_convert', $code);
}
return preg_replace("/\<([\/]?)(script|iframe|form)([^\>]*)\>?/i", "&lt;$1$2$3&gt;", $code);
}
function _callback_bad_tag_convert($matches){
return "<div class=\"embedx\">보안문제로 인하여 관리자 아이디로는 embed 또는 object 태그를 볼 수 없습니다. 확인하시려면 관리권한이 없는 다른 아이디로 접속하세요.</div>";
}
// 토큰 생성
function _token()
+1 -1
View File
@@ -91,7 +91,7 @@ function get_pretty_url($folder, $no='', $query_string='', $action='')
$url .= ($folder === 'content') ? '?co_id='. $no : '?'. $no;
}
if($query_string) {
$url .= ($no ? '?' : '&amp;'). $query_string;
$url .= (!$no ? '?' : '&amp;'). $query_string;
}
}
+1 -1
View File
@@ -16,7 +16,7 @@ $result = sql_query($sql, false);
for ($i=0; $nw=sql_fetch_array($result); $i++)
{
// 이미 체크 되었다면 Continue
if ($_COOKIE["hd_pops_{$nw['nw_id']}"])
if (isset($_COOKIE["hd_pops_{$nw['nw_id']}"]) && $_COOKIE["hd_pops_{$nw['nw_id']}"])
continue;
?>
+4 -3
View File
@@ -28,7 +28,8 @@ $is_show_next_prev = ($list_count > 4) ? 1 : 0;
$thumb = get_list_thumbnail($bo_table, $list[$i]['wr_id'], $thumb_width, $thumb_height, false, true);
$img = $thumb['src'] ? $thumb['src'] : '';
$img_content = $img ? '<img src="'.$img.'" alt="'.$thumb['alt'].'" >' : '';
$wr_href = get_pretty_url($bo_table, $list[$i]['wr_id']);
$echo_ul = ( $i && (($i % $divisor_count) === 0) ) ? '</ul><ul class="item">'.PHP_EOL : '';
echo $echo_ul;
@@ -38,10 +39,10 @@ $is_show_next_prev = ($list_count > 4) ? 1 : 0;
//echo $list[$i]['icon_reply']." ";
if( $img_content ){
echo "<a href=\"".$list[$i]['href']."\" class=\"lt_thumb\">".run_replace('thumb_image_tag', $img_content, $thumb)."</a> ";
echo "<a href=\"".$wr_href."\" class=\"lt_thumb\">".run_replace('thumb_image_tag', $img_content, $thumb)."</a> ";
}
echo "<a href=\"".$list[$i]['href']."\" class=\"lt_tit\">";
echo "<a href=\"".$wr_href."\" class=\"lt_tit\">";
if ($list[$i]['icon_secret']) echo "<i class=\"fa fa-lock\" aria-hidden=\"true\"></i> ";
if ($list[$i]['is_notice'])
echo "<strong>".$list[$i]['subject']."</strong>";
+1 -1
View File
@@ -15,7 +15,7 @@ $list_count = (is_array($list) && $list) ? count($list) : 0;
<li>
<span class="cm_lt_nick"><?php echo get_member_profile_img($member['mb_id']); ?></span>
<div class="cm_lt_info">
<a href="<?php echo $list[$i]['href']; ?>" class="over"><?php echo $list[$i]['subject']; ?></a>
<a href="<?php echo get_pretty_url($bo_table, $list[$i]['wr_id']); ?>" class="over"><?php echo $list[$i]['subject']; ?></a>
<br>
<span class="lt_nick"><?php echo $list[$i]['name'] ?></span>
<span class="lt_date"><?php echo $list[$i]['datetime2'] ?></span>
+1 -1
View File
@@ -16,7 +16,7 @@ $list_count = (is_array($list) && $list) ? count($list) : 0;
if ($list[$i]['icon_secret']) echo "<span class=\"lock_icon\"><i class=\"fa fa-lock\" aria-hidden=\"true\"></i></span> ";
if ($list[$i]['icon_new']) echo "<span class=\"new_icon\">N<span class=\"sound_only\">새글</span></span>";
//echo $list[$i]['icon_reply']." ";
echo "<a href=\"".$list[$i]['href']."\">";
echo "<a href=\"".get_pretty_url($bo_table, $list[$i]['wr_id'])."\">";
if ($list[$i]['is_notice'])
echo "<strong>".$list[$i]['subject']."</strong>";
else
+5 -8
View File
@@ -18,13 +18,9 @@ add_stylesheet('<link rel="stylesheet" href="'.$member_skin_url.'/style.css">',
<ul class="point_list">
<?php
$sum_point1 = $sum_point2 = $sum_point3 = 0;
$sql = " select *
{$sql_common}
{$sql_order}
limit {$from_record}, {$rows} ";
$result = sql_query($sql);
for ($i=0; $row=sql_fetch_array($result); $i++) {
$i = 0;
foreach((array) $list as $row){
$point1 = $point2 = 0;
$point_use_class = '';
if ($row['po_point'] > 0) {
@@ -55,7 +51,8 @@ add_stylesheet('<link rel="stylesheet" href="'.$member_skin_url.'/style.css">',
</span>
</li>
<?php
}
$i++;
} // end foreach
if ($i == 0)
echo '<li class="empty_list">자료가 없습니다.</li>';
+1 -1
View File
@@ -14,7 +14,7 @@ $list_count = (is_array($list) && $list) ? count($list) : 0;
<?php
if ($list[$i]['icon_secret']) echo "<i class=\"fa fa-lock\" aria-hidden=\"true\"></i><span class=\"sound_only\">비밀글</span> ";
echo "<a href=\"".$list[$i]['href']."\"> ";
echo "<a href=\"".get_pretty_url($bo_table, $list[$i]['wr_id'])."\"> ";
if ($list[$i]['is_notice'])
echo "<strong>".$list[$i]['subject']."</strong>";
else
+1 -1
View File
@@ -16,7 +16,7 @@ $list_count = (is_array($list) && $list) ? count($list) : 0;
if ($list[$i]['icon_secret']) echo "<span class=\"lock_icon\"><i class=\"fa fa-lock\" aria-hidden=\"true\"></i></span> ";
if ($list[$i]['icon_new']) echo "<span class=\"new_icon\">N<span class=\"sound_only\">새글</span></span>";
//echo $list[$i]['icon_reply']." ";
echo "<a href=\"".$list[$i]['href']."\">";
echo "<a href=\"".get_pretty_url($bo_table, $list[$i]['wr_id'])."\">";
if ($list[$i]['is_notice'])
echo "<strong>".$list[$i]['subject']."</strong>";
else
+3 -2
View File
@@ -23,13 +23,14 @@ $list_count = (is_array($list) && $list) ? count($list) : 0;
$thumb['alt'] = '이미지가 없습니다.';
}
$img_content = '<img src="'.$img.'" alt="'.$thumb['alt'].'" >';
$wr_href = get_pretty_url($bo_table, $list[$i]['wr_id']);
?>
<li class="gallery_li">
<a href="<?php echo $list[$i]['href'] ?>" class="lt_img"><?php echo run_replace('thumb_image_tag', $img_content, $thumb); ?></a>
<a href="<?php echo $wr_href; ?>" class="lt_img"><?php echo run_replace('thumb_image_tag', $img_content, $thumb); ?></a>
<?php
if ($list[$i]['icon_secret']) echo "<i class=\"fa fa-lock\" aria-hidden=\"true\"></i><span class=\"sound_only\">비밀글</span> ";
echo "<a href=\"".$list[$i]['href']."\"> ";
echo "<a href=\"".$wr_href."\"> ";
if ($list[$i]['is_notice'])
echo "<strong>".$list[$i]['subject']."</strong>";
else
+4 -2
View File
@@ -17,6 +17,8 @@ $list_count = (is_array($list) && $list) ? count($list) : 0;
$img_link_html = '';
$wr_href = get_pretty_url($bo_table, $list[$i]['wr_id']);
if( $i === 0 ) {
$thumb = get_list_thumbnail($bo_table, $list[$i]['wr_id'], $thumb_width, $thumb_height, false, true);
@@ -27,7 +29,7 @@ $list_count = (is_array($list) && $list) ? count($list) : 0;
$thumb['alt'] = '이미지가 없습니다.';
}
$img_content = '<img src="'.$img.'" alt="'.$thumb['alt'].'" >';
$img_link_html = '<a href="'.$list[$i]['href'].'" class="lt_img" >'.run_replace('thumb_image_tag', $img_content, $thumb).'</a>';
$img_link_html = '<a href="'.$wr_href.'" class="lt_img" >'.run_replace('thumb_image_tag', $img_content, $thumb).'</a>';
}
?>
<li>
@@ -35,7 +37,7 @@ $list_count = (is_array($list) && $list) ? count($list) : 0;
<?php
if ($list[$i]['icon_secret']) echo "<i class=\"fa fa-lock\" aria-hidden=\"true\"></i><span class=\"sound_only\">비밀글</span> ";
echo "<a href=\"".$list[$i]['href']."\" class=\"pic_li_tit\"> ";
echo "<a href=\"".$wr_href."\" class=\"pic_li_tit\"> ";
if ($list[$i]['is_notice'])
echo "<strong>".$list[$i]['subject']."</strong>";
else
+5 -8
View File
@@ -18,13 +18,9 @@ add_stylesheet('<link rel="stylesheet" href="'.$member_skin_url.'/style.css">',
<ul class="point_list">
<?php
$sum_point1 = $sum_point2 = $sum_point3 = 0;
$sql = " select *
{$sql_common}
{$sql_order}
limit {$from_record}, {$rows} ";
$result = sql_query($sql);
for ($i=0; $row=sql_fetch_array($result); $i++) {
$i = 0;
foreach((array) $list as $row){
$point1 = $point2 = 0;
$point_use_class = '';
if ($row['po_point'] > 0) {
@@ -55,7 +51,8 @@ add_stylesheet('<link rel="stylesheet" href="'.$member_skin_url.'/style.css">',
</span>
</li>
<?php
}
$i++;
} // end foreach
if ($i == 0)
echo '<li class="empty_li">자료가 없습니다.</li>';
@@ -28,7 +28,8 @@ $is_show_next_prev = ($list_count > 4) ? 1 : 0;
$thumb = get_list_thumbnail($bo_table, $list[$i]['wr_id'], $thumb_width, $thumb_height, false, true);
$img = $thumb['src'] ? $thumb['src'] : '';
$img_content = $img ? '<img src="'.$img.'" alt="'.$thumb['alt'].'" >' : '';
$wr_href = get_pretty_url($bo_table, $list[$i]['wr_id']);
$echo_ul = ( $i && (($i % $divisor_count) === 0) ) ? '</ul><ul class="item">'.PHP_EOL : '';
echo $echo_ul;
@@ -38,10 +39,10 @@ $is_show_next_prev = ($list_count > 4) ? 1 : 0;
//echo $list[$i]['icon_reply']." ";
if( $img_content ){
echo "<a href=\"".$list[$i]['href']."\" class=\"lt_thumb\">".run_replace('thumb_image_tag', $img_content, $thumb)."</a> ";
echo "<a href=\"".$wr_href."\" class=\"lt_thumb\">".run_replace('thumb_image_tag', $img_content, $thumb)."</a> ";
}
echo "<a href=\"".$list[$i]['href']."\" class=\"lt_tit\">";
echo "<a href=\"".$wr_href."\" class=\"lt_tit\">";
if ($list[$i]['icon_secret']) echo "<i class=\"fa fa-lock\" aria-hidden=\"true\"></i> ";
if ($list[$i]['is_notice'])
echo "<strong>".$list[$i]['subject']."</strong>";
@@ -15,7 +15,7 @@ $list_count = (is_array($list) && $list) ? count($list) : 0;
<li>
<span class="cm_lt_nick"><?php echo get_member_profile_img($member['mb_id']); ?></span>
<div class="cm_lt_info">
<a href="<?php echo $list[$i]['href']; ?>" class="over"><?php echo $list[$i]['subject']; ?></a>
<a href="<?php echo get_pretty_url($bo_table, $list[$i]['wr_id']); ?>" class="over"><?php echo $list[$i]['subject']; ?></a>
<br>
<span class="lt_nick"><?php echo $list[$i]['name'] ?></span>
<span class="lt_date"><?php echo $list[$i]['datetime2'] ?></span>
@@ -16,7 +16,7 @@ $list_count = (is_array($list) && $list) ? count($list) : 0;
if ($list[$i]['icon_secret']) echo "<span class=\"lock_icon\"><i class=\"fa fa-lock\" aria-hidden=\"true\"></i></span> ";
if ($list[$i]['icon_new']) echo "<span class=\"new_icon\">N<span class=\"sound_only\">새글</span></span>";
//echo $list[$i]['icon_reply']." ";
echo "<a href=\"".$list[$i]['href']."\">";
echo "<a href=\"".get_pretty_url($bo_table, $list[$i]['wr_id'])."\">";
if ($list[$i]['is_notice'])
echo "<strong>".$list[$i]['subject']."</strong>";
else
@@ -19,12 +19,8 @@ add_stylesheet('<link rel="stylesheet" href="'.$member_skin_url.'/style.css">',
<?php
$sum_point1 = $sum_point2 = $sum_point3 = 0;
$sql = " select *
{$sql_common}
{$sql_order}
limit {$from_record}, {$rows} ";
$result = sql_query($sql);
for ($i=0; $row=sql_fetch_array($result); $i++) {
$i = 0;
foreach((array) $list as $row){
$point1 = $point2 = 0;
$point_use_class = '';
if ($row['po_point'] > 0) {
@@ -55,7 +51,8 @@ add_stylesheet('<link rel="stylesheet" href="'.$member_skin_url.'/style.css">',
</span>
</li>
<?php
}
$i++;
} // end foreach
if ($i == 0)
echo '<li class="empty_list">자료가 없습니다.</li>';
@@ -14,7 +14,7 @@ $list_count = (is_array($list) && $list) ? count($list) : 0;
<?php
if ($list[$i]['icon_secret']) echo "<i class=\"fa fa-lock\" aria-hidden=\"true\"></i><span class=\"sound_only\">비밀글</span> ";
echo "<a href=\"".$list[$i]['href']."\"> ";
echo "<a href=\"".get_pretty_url($bo_table, $list[$i]['wr_id'])."\"> ";
if ($list[$i]['is_notice'])
echo "<strong>".$list[$i]['subject']."</strong>";
else
@@ -16,7 +16,7 @@ $list_count = (is_array($list) && $list) ? count($list) : 0;
if ($list[$i]['icon_secret']) echo "<span class=\"lock_icon\"><i class=\"fa fa-lock\" aria-hidden=\"true\"></i></span> ";
if ($list[$i]['icon_new']) echo "<span class=\"new_icon\">N<span class=\"sound_only\">새글</span></span>";
//echo $list[$i]['icon_reply']." ";
echo "<a href=\"".$list[$i]['href']."\">";
echo "<a href=\"".get_pretty_url($bo_table, $list[$i]['wr_id'])."\">";
if ($list[$i]['is_notice'])
echo "<strong>".$list[$i]['subject']."</strong>";
else
@@ -23,13 +23,14 @@ $list_count = (is_array($list) && $list) ? count($list) : 0;
$thumb['alt'] = '이미지가 없습니다.';
}
$img_content = '<img src="'.$img.'" alt="'.$thumb['alt'].'" >';
$wr_href = get_pretty_url($bo_table, $list[$i]['wr_id']);
?>
<li class="galley_li">
<a href="<?php echo $list[$i]['href'] ?>" class="lt_img"><?php echo run_replace('thumb_image_tag', $img_content, $thumb); ?></a>
<a href="<?php echo $wr_href; ?>" class="lt_img"><?php echo run_replace('thumb_image_tag', $img_content, $thumb); ?></a>
<?php
if ($list[$i]['icon_secret']) echo "<i class=\"fa fa-lock\" aria-hidden=\"true\"></i><span class=\"sound_only\">비밀글</span> ";
echo "<a href=\"".$list[$i]['href']."\"> ";
echo "<a href=\"".$wr_href."\"> ";
if ($list[$i]['is_notice'])
echo "<strong>".$list[$i]['subject']."</strong>";
else
@@ -16,6 +16,8 @@ $list_count = (is_array($list) && $list) ? count($list) : 0;
for ($i=0; $i<$list_count; $i++) {
$img_link_html = '';
$wr_href = get_pretty_url($bo_table, $list[$i]['wr_id']);
if( $i === 0 ) {
$thumb = get_list_thumbnail($bo_table, $list[$i]['wr_id'], $thumb_width, $thumb_height, false, true);
@@ -27,7 +29,7 @@ $list_count = (is_array($list) && $list) ? count($list) : 0;
$thumb['alt'] = '이미지가 없습니다.';
}
$img_content = '<img src="'.$img.'" alt="'.$thumb['alt'].'" >';
$img_link_html = '<a href="'.$list[$i]['href'].'" class="lt_img" >'.run_replace('thumb_image_tag', $img_content, $thumb).'</a>';
$img_link_html = '<a href="'.$wr_href.'" class="lt_img" >'.run_replace('thumb_image_tag', $img_content, $thumb).'</a>';
}
?>
<li>
@@ -35,7 +37,7 @@ $list_count = (is_array($list) && $list) ? count($list) : 0;
<?php
if ($list[$i]['icon_secret']) echo "<i class=\"fa fa-lock\" aria-hidden=\"true\"></i><span class=\"sound_only\">비밀글</span> ";
echo "<a href=\"".$list[$i]['href']."\" class=\"pic_li_tit\"> ";
echo "<a href=\"".$wr_href."\" class=\"pic_li_tit\"> ";
if ($list[$i]['is_notice'])
echo "<strong>".$list[$i]['subject']."</strong>";
else
+4 -7
View File
@@ -19,12 +19,8 @@ add_stylesheet('<link rel="stylesheet" href="'.$member_skin_url.'/style.css">',
<?php
$sum_point1 = $sum_point2 = $sum_point3 = 0;
$sql = " select *
{$sql_common}
{$sql_order}
limit {$from_record}, {$rows} ";
$result = sql_query($sql);
for ($i=0; $row=sql_fetch_array($result); $i++) {
$i = 0;
foreach((array) $list as $row){
$point1 = $point2 = 0;
$point_use_class = '';
if ($row['po_point'] > 0) {
@@ -55,7 +51,8 @@ add_stylesheet('<link rel="stylesheet" href="'.$member_skin_url.'/style.css">',
</span>
</li>
<?php
}
$i++;
} // end foreach
if ($i == 0)
echo '<li class="empty_li">자료가 없습니다.</li>';