From cad9888a3ee66b1b6e7168c9c36aa803472e769d Mon Sep 17 00:00:00 2001 From: chicpro Date: Mon, 18 Mar 2013 13:42:09 +0900 Subject: [PATCH 1/3] =?UTF-8?q?=EA=B0=A4=EB=9F=AC=EB=A6=AC=EC=8A=A4?= =?UTF-8?q?=ED=82=A8=EC=97=90=EC=84=9C=20=EC=97=90=EB=94=94=ED=84=B0?= =?UTF-8?q?=EB=A1=9C=20=EC=B2=A8=EB=B6=80=EB=90=9C=20=EC=9D=B4=EB=AF=B8?= =?UTF-8?q?=EC=A7=80=20=EC=8D=B8=EB=84=A4=EC=9D=BC=20=EC=83=9D=EC=84=B1=20?= =?UTF-8?q?=EA=B8=B0=EB=8A=A5=20=EC=B6=94=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lib/thumbnail.lib.php | 57 ++++++++++++++++++++++++- mobile/skin/board/gallery/list.skin.php | 11 ++--- skin/board/gallery/list.skin.php | 9 ++-- 3 files changed, 62 insertions(+), 15 deletions(-) diff --git a/lib/thumbnail.lib.php b/lib/thumbnail.lib.php index 755058a60..baf036d69 100644 --- a/lib/thumbnail.lib.php +++ b/lib/thumbnail.lib.php @@ -9,9 +9,62 @@ function it_img_thumb($filename, $filepath, $thumb_width, $thumb_height, $is_cre } // 게시글리스트 썸네일 생성 -function get_list_thumbnail($filename, $filepath, $thumb_width, $thumb_height, $is_create=false, $is_crop=true) +function get_list_thumbnail($bo_table, $wr_id, $thumb_width, $thumb_height, $is_create=false, $is_crop=true) { - return thumbnail($filename, $filepath, $filepath, $thumb_width, $thumb_height, $is_create, $is_crop); + global $g4, $config; + $filename = $alt = ""; + $edt = false; + + $sql = " select bf_file, bf_content from {$g4['board_file_table']} + where bo_table = '$bo_table' and wr_id = '$wr_id' and bf_type between '1' and '3' order by bf_no limit 0, 1 "; + $row = sql_fetch($sql); + + if($row['bf_file']) { + $filename = $row['bf_file']; + $filepath = G4_DATA_PATH.'/file/'.$bo_table; + $src_url = G4_DATA_URL.'/file/'.$bo_table; + $alt = get_text($row['bf_content']); + } else { + $write_table = $g4['write_prefix'].$bo_table; + $sql = " select wr_content from $write_table where wr_id = '$wr_id' "; + $write = sql_fetch($sql); + $matchs = get_editor_image($write['wr_content']); + $edt = true; + + for($i=0; $i$src, "alt"=>$alt); + + return $thumb; } // 게시글보기 썸네일 생성 diff --git a/mobile/skin/board/gallery/list.skin.php b/mobile/skin/board/gallery/list.skin.php index 8dc2e80b3..3f2e04926 100644 --- a/mobile/skin/board/gallery/list.skin.php +++ b/mobile/skin/board/gallery/list.skin.php @@ -87,15 +87,12 @@ include_once(G4_LIB_PATH.'/thumbnail.lib.php'); 공지 '; + if($thumb['src']) { + $img_content = ''.$thumb['alt'].''; } else { - $img_content = 'no image'; + $img_content = 'no image'; } echo $img_content; diff --git a/skin/board/gallery/list.skin.php b/skin/board/gallery/list.skin.php index f15321fc9..e5f382fd6 100644 --- a/skin/board/gallery/list.skin.php +++ b/skin/board/gallery/list.skin.php @@ -72,13 +72,10 @@ include_once(G4_LIB_PATH.'/thumbnail.lib.php'); 공지 '; + if($thumb['src']) { + $img_content = ''.$thumb['alt'].''; } else { $img_content = 'no image'; } From 7956b4f02ffa096750c1ca3add7676a54a6b12db Mon Sep 17 00:00:00 2001 From: chicpro Date: Mon, 18 Mar 2013 13:52:53 +0900 Subject: [PATCH 2/3] =?UTF-8?q?gmail=EB=A1=9C=20=EB=A9=94=EC=9D=BC=20?= =?UTF-8?q?=EB=B0=9C=EC=86=A1=EC=8B=9C=20=EC=A0=9C=EB=AA=A9=20=EA=B9=A8?= =?UTF-8?q?=EC=A7=80=EB=8A=94=20=EC=98=A4=EB=A5=98=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lib/mailer.lib.php | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/lib/mailer.lib.php b/lib/mailer.lib.php index d6f58c05f..f816a3d7d 100644 --- a/lib/mailer.lib.php +++ b/lib/mailer.lib.php @@ -11,8 +11,10 @@ function mailer($fname, $fmail, $to, $subject, $content, $type=0, $file='', $cc= // 메일발송 사용을 하지 않는다면 if (!$config['cf_email_use']) return; - $fname = "=?$g4[charset]?B?" . base64_encode($fname) . "?="; - $subject = "=?$g4[charset]?B?" . base64_encode($subject) . "?="; + //$fname = "=?$g4[charset]?B?" . base64_encode($fname) . "?="; + //$subject = "=?$g4[charset]?B?" . base64_encode($subject) . "?="; + $fname = "=?utf-8?B?" . base64_encode($fname) . "?="; + $subject = "=?utf-8?B?" . base64_encode($subject) . "?="; //$g4[charset] = ($g4[charset] != "") ? "charset=$g4[charset]" : ""; $header = "Return-Path: <$fmail>\n"; @@ -31,11 +33,11 @@ function mailer($fname, $fmail, $to, $subject, $content, $type=0, $file='', $cc= } if ($type) { - $header .= "Content-Type: TEXT/HTML; charset=$g4[charset]\n"; + $header .= "Content-Type: TEXT/HTML; charset=utf-8\n"; if ($type == 2) $content = nl2br($content); } else { - $header .= "Content-Type: TEXT/PLAIN; charset=$g4[charset]\n"; + $header .= "Content-Type: TEXT/PLAIN; charset=utf-8\n"; $content = stripslashes($content); } $header .= "Content-Transfer-Encoding: BASE64\n\n"; From 3c3710a092409d49f2235b7ce35c411b1ba1d63b Mon Sep 17 00:00:00 2001 From: chicpro Date: Mon, 18 Mar 2013 14:04:52 +0900 Subject: [PATCH 3/3] =?UTF-8?q?=EB=A1=9C=EA=B7=B8=EC=9D=B8=20=EC=B2=B4?= =?UTF-8?q?=ED=81=AC=20=EC=98=A4=EB=A5=98=EB=A9=94=EC=84=B8=EC=A7=80=20\n?= =?UTF-8?q?=EC=9D=84=20\\n=EC=9C=BC=EB=A1=9C=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- bbs/login_check.php | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/bbs/login_check.php b/bbs/login_check.php index 8bb298a68..011cae8ea 100644 --- a/bbs/login_check.php +++ b/bbs/login_check.php @@ -11,27 +11,27 @@ if (!trim($mb_id) || !trim($mb_password)) $mb = get_member($mb_id); -// 가입된 회원이 아니다. 패스워드가 틀리다. 라는 메세지를 따로 보여주지 않는 이유는 +// 가입된 회원이 아니다. 패스워드가 틀리다. 라는 메세지를 따로 보여주지 않는 이유는 // 회원아이디를 입력해 보고 맞으면 또 패스워드를 입력해보는 경우를 방지하기 위해서입니다. // 불법사용자의 경우 회원아이디가 틀린지, 패스워드가 틀린지를 알기까지는 많은 시간이 소요되기 때문입니다. if (!$mb['mb_id'] || (sql_password($mb_password) != $mb['mb_password'])) { - alert('가입된 회원아이디가 아니거나 패스워드가 틀립니다.\n패스워드는 대소문자를 구분합니다.'); + alert('가입된 회원아이디가 아니거나 패스워드가 틀립니다.\\n패스워드는 대소문자를 구분합니다.'); } // 차단된 아이디인가? if ($mb['mb_intercept_date'] && $mb['mb_intercept_date'] <= date("Ymd", G4_SERVER_TIME)) { - $date = preg_replace("/([0-9]{4})([0-9]{2})([0-9]{2})/", "\\1년 \\2월 \\3일", $mb['mb_intercept_date']); + $date = preg_replace("/([0-9]{4})([0-9]{2})([0-9]{2})/", "\\1년 \\2월 \\3일", $mb['mb_intercept_date']); alert('회원님의 아이디는 접근이 금지되어 있습니다.\n처리일 : '.$date); } // 탈퇴한 아이디인가? if ($mb['mb_leave_date'] && $mb['mb_leave_date'] <= date("Ymd", G4_SERVER_TIME)) { - $date = preg_replace("/([0-9]{4})([0-9]{2})([0-9]{2})/", "\\1년 \\2월 \\3일", $mb['mb_leave_date']); + $date = preg_replace("/([0-9]{4})([0-9]{2})([0-9]{2})/", "\\1년 \\2월 \\3일", $mb['mb_leave_date']); alert('탈퇴한 아이디이므로 접근하실 수 없습니다.\n탈퇴일 : '.$date); } if ($config['cf_use_email_certify'] && !preg_match("/[1-9]/", $mb['mb_email_certify'])) - alert('메일인증을 받으셔야 로그인 하실 수 있습니다.\n회원님의 메일주소는 '.$mb['mb_email'].' 입니다.'); + alert('메일인증을 받으셔야 로그인 하실 수 있습니다.\\n회원님의 메일주소는 '.$mb['mb_email'].' 입니다.'); @include_once($member_skin_path.'/login_check.skin.php'); @@ -59,9 +59,9 @@ if ($url) { $link = urldecode($url); // 2003-06-14 추가 (다른 변수들을 넘겨주기 위함) if (preg_match("/\?/", $link)) - $split= "&"; + $split= "&"; else - $split= "?"; + $split= "?"; // $_POST 배열변수에서 아래의 이름을 가지지 않은 것만 넘김 foreach($_POST as $key=>$value) {