diff --git a/adm/admin.lib.php b/adm/admin.lib.php
index 0ea37f4d7..df560e7d8 100644
--- a/adm/admin.lib.php
+++ b/adm/admin.lib.php
@@ -70,7 +70,7 @@ function member_delete($mb_id)
}
// 회원자료는 정보만 없앤 후 아이디는 보관하여 다른 사람이 사용하지 못하도록 함 : 061025
- $sql = " update {$g4['member_table']} set mb_jumin = '', mb_password = '', mb_level = 1, mb_email = '', mb_homepage = '', mb_password_q = '', mb_password_a = '', mb_tel = '', mb_hp = '', mb_zip1 = '', mb_zip2 = '', mb_addr1 = '', mb_addr2 = '', mb_birth = '', mb_sex = '', mb_signature = '', mb_memo = '".date('Ymd', G4_SERVER_TIME)." 삭제함".PHP_EOL."{$mb['mb_memo']}', mb_leave_date = '".date('Ymd', G4_SERVER_TIME)."' where mb_id = '{$mb_id}' ";
+ $sql = " update {$g4['member_table']} set mb_jumin = '', mb_password = '', mb_level = 1, mb_email = '', mb_homepage = '', mb_password_q = '', mb_password_a = '', mb_tel = '', mb_hp = '', mb_zip1 = '', mb_zip2 = '', mb_addr1 = '', mb_addr2 = '', mb_birth = '', mb_sex = '', mb_signature = '', mb_memo = '".date('Ymd', G4_SERVER_TIME)." 삭제함\n{$mb['mb_memo']}', mb_leave_date = '".date('Ymd', G4_SERVER_TIME)."' where mb_id = '{$mb_id}' ";
sql_query($sql);
}
@@ -176,7 +176,7 @@ function help($help="")
{
global $g4;
- $str = ''.$help.' ';
+ $str = ''.str_replace("\n", " ", $help).' ';
return $str;
}
diff --git a/adm/auth_list.php b/adm/auth_list.php
index ec8bde957..cb8a41da7 100644
--- a/adm/auth_list.php
+++ b/adm/auth_list.php
@@ -138,7 +138,7 @@ $colspan = 5;
//if (isset($stx))
- // echo ''.PHP_EOL;
+ // echo ''."\n";
if (strstr($sfl, 'mb_id'))
$mb_id = $stx;
diff --git a/adm/board_form.php b/adm/board_form.php
index 9b70a64b6..47f72395c 100644
--- a/adm/board_form.php
+++ b/adm/board_form.php
@@ -185,7 +185,7 @@ $pg_anchor = "
카운트 조정
- =help('현재 원글수 : '.number_format($board['bo_count_write']).', 현재 댓글수 : '.number_format($board['bo_count_comment']).PHP_EOL.'게시판 목록에서 글의 번호가 맞지 않을 경우에 체크하십시오.')?>
+ =help('현재 원글수 : '.number_format($board['bo_count_write']).', 현재 댓글수 : '.number_format($board['bo_count_comment'])."\n".'게시판 목록에서 글의 번호가 맞지 않을 경우에 체크하십시오.')?>
@@ -457,7 +457,8 @@ $pg_anchor = "
그룹적용
-
+
+
전체적용
@@ -809,8 +810,8 @@ $pg_anchor = "
그룹적용
-
- 전체적용
+
+ 전체적용
@@ -833,10 +834,10 @@ $pg_anchor = "
@@ -846,10 +847,10 @@ $pg_anchor = "
@@ -859,10 +860,10 @@ $pg_anchor = "
diff --git a/adm/config_form.php b/adm/config_form.php
index 1c019aca9..f63dd2864 100644
--- a/adm/config_form.php
+++ b/adm/config_form.php
@@ -191,7 +191,7 @@ $pg_anchor = "
$arr = get_skin_dir('new');
for ($i=0; $i".$arr[$i]."".PHP_EOL;
+ echo "".$arr[$i]." \n";
}
?>
@@ -202,7 +202,7 @@ $pg_anchor = "
$arr = get_skin_dir('new', G4_MOBILE_PATH.'/'.G4_SKIN_DIR);
for ($i=0; $i".$arr[$i]."".PHP_EOL;
+ echo "".$arr[$i]." \n";
}
?>
@@ -215,7 +215,7 @@ $pg_anchor = "
$arr = get_skin_dir('search');
for ($i=0; $i".$arr[$i]."".PHP_EOL;
+ echo "".$arr[$i]." \n";
}
?>
@@ -226,7 +226,7 @@ $pg_anchor = "
$arr = get_skin_dir('search', G4_MOBILE_PATH.'/'.G4_SKIN_DIR);
for ($i=0; $i".$arr[$i]."".PHP_EOL;
+ echo "".$arr[$i]." \n";
}
?>
@@ -239,7 +239,7 @@ $pg_anchor = "
$arr = get_skin_dir('connect');
for ($i=0; $i".$arr[$i]."".PHP_EOL;
+ echo "".$arr[$i]." \n";
}
?>
@@ -250,7 +250,7 @@ $pg_anchor = "
$arr = get_skin_dir('connect', G4_MOBILE_PATH.'/'.G4_SKIN_DIR);
for ($i=0; $i".$arr[$i]."".PHP_EOL;
+ echo "".$arr[$i]." \n";
}
?>
@@ -374,7 +374,7 @@ $pg_anchor = "
$arr = get_skin_dir('member');
for ($i=0; $i'.$arr[$i].''.PHP_EOL;
+ echo ''.$arr[$i].' '."\n";
}
?>
@@ -385,7 +385,7 @@ $pg_anchor = "
$arr = get_skin_dir('member', G4_MOBILE_PATH.'/'.G4_SKIN_DIR);
for ($i=0; $i'.$arr[$i].''.PHP_EOL;
+ echo ''.$arr[$i].' '."\n";
}
?>
diff --git a/adm/member_form_update.php b/adm/member_form_update.php
index 212e7ea82..1f33070ff 100644
--- a/adm/member_form_update.php
+++ b/adm/member_form_update.php
@@ -15,12 +15,35 @@ if ($member['mb_password'] != sql_password($_POST['admin_password'])) {
$mb_id = mysql_real_escape_string(trim($_POST['mb_id']));
+// 핸드폰번호 체크
+$mb_hp = $_POST['mb_hp'];
+if($mb_hp) {
+ $mb_hp = preg_replace("/[^0-9]/", "", $mb_hp);
+ $hp_len = strlen($mb_hp);
+ if($hp_len == 10) {
+ $mb_hp = preg_replace("/([0-9]{3})([0-9]{3})([0-9]{4})/", "\\1-\\2-\\3", $mb_hp);
+ } else if($hp_len == 11) {
+ $mb_hp = preg_replace("/([0-9]{3})([0-9]{4})([0-9]{4})/", "\\1-\\2-\\3", $mb_hp);
+ } else {
+ alert('핸드폰번호를 올바르게 입력해 주십시오.');
+ }
+
+ // 중복체크
+ $sql = " select count(*) as cnt from {$g4['member_table']} where mb_hp = '$mb_hp' ";
+ if($w == 'u')
+ $sql .= " and mb_id <> '$mb_id' ";
+
+ $row = sql_fetch($sql);
+ if($row['cnt'])
+ alert('다른 회원이 사용 중인 핸드폰번호입니다.');
+}
+
$sql_common = " mb_name = '{$_POST['mb_name']}',
mb_nick = '{$_POST['mb_nick']}',
mb_email = '{$_POST['mb_email']}',
mb_homepage = '{$_POST['mb_homepage']}',
mb_tel = '{$_POST['mb_tel']}',
- mb_hp = '{$_POST['mb_hp']}',
+ mb_hp = '$mb_hp',
mb_zip1 = '{$_POST['mb_zip1']}',
mb_zip2 = '{$_POST['mb_zip2']}',
mb_addr1 = '{$_POST['mb_addr1']}',
diff --git a/adm/point_clear.php b/adm/point_clear.php
index 84523d6ed..3006816d2 100644
--- a/adm/point_clear.php
+++ b/adm/point_clear.php
@@ -16,7 +16,7 @@ echo ' ';
include_once('./admin.tail.php');
flush();
-echo ''.PHP_EOL;
+echo ''."\n";
flush();
$max_count = 50;
@@ -52,7 +52,7 @@ for ($i=0; $row=sql_fetch_array($result); $i++)
insert_point($row['mb_id'], $total, '포인트 {$count}건 정리', '@clear', $row['mb_id'], G4_TIME_YMD."-".uniqid(""));
$str = $row['mb_id']."님 포인트 내역 ".number_format($count)."건 ".number_format($total)."점 정리 ";
- echo ''.PHP_EOL;
+ echo ''."\n";
flush();
}
@@ -60,5 +60,5 @@ for ($i=0; $row=sql_fetch_array($result); $i++)
$sql = " UNLOCK TABLES ";
sql_query($sql);
-echo ''.PHP_EOL;
+echo ''."\n";
?>
diff --git a/bbs/ckeditor/ckeditor.lib.php b/bbs/ckeditor/ckeditor.lib.php
index 26017287d..b27798394 100644
--- a/bbs/ckeditor/ckeditor.lib.php
+++ b/bbs/ckeditor/ckeditor.lib.php
@@ -1,16 +1,16 @@
';
- $html .= PHP_EOL.'';
- $html .= PHP_EOL.'';
+ $html .= "\n".'';
+ $html .= "\n".'';
+ $html .= "\n".'';
$js = false;
}
@@ -21,7 +21,7 @@ function editor_html($id, $content, $ckeditor=true, $class="")
// textarea 로 값을 넘긴다. javascript 반드시 필요
-function get_editor_js($id, $ckeditor=true)
+function get_editor_js($id, $ckeditor=true)
{
if ( $ckeditor ) {
return "var {$id}_editor_data = CKEDITOR.instances.{$id}.getData();\n";
diff --git a/bbs/gcaptcha/gcaptcha.lib.php b/bbs/gcaptcha/gcaptcha.lib.php
index a1b9af3a2..b8c6772fc 100644
--- a/bbs/gcaptcha/gcaptcha.lib.php
+++ b/bbs/gcaptcha/gcaptcha.lib.php
@@ -1,7 +1,7 @@
get_captcha_key();
-
+
set_session('ss_captcha_cnt', 0);
set_session('ss_captcha_key', $captcha_key);
@@ -125,7 +125,7 @@ class gcaptcha
imagejpeg($im, G4_DATA_PATH.'/cache/'.$this->captcha_filename.'.jpg');
imagedestroy($im);
- $this->make_wav($this->captcha_filename.'.wav');
+ $this->make_wav($this->captcha_filename.'.wav');
}
function get_captcha_filename()
@@ -152,7 +152,7 @@ class gcaptcha
}
/*
-사용법 :
+사용법 :
$gcaptcha = new gcaptcha();
$gcaptcha->set_captcha_length(mt_rand(4, 6));
$gcaptcha->set_position(mt_rand(0, 10), mt_rand(15, 20));
@@ -172,15 +172,16 @@ function captcha_html($class='captcha')
$obj = new gcaptcha();
$obj->run();
+ $rand = rand();
$jpg_file_url = G4_DATA_URL.'/cache/'.$obj->captcha_filename.'.jpg';
$wav_file_url = G4_DATA_URL.'/cache/'.$obj->captcha_filename.'.wav';
- $html .= PHP_EOL.'';
- $html .= PHP_EOL.'';
+ $html .= "\n".'';
+ $html .= "\n".'';
$html .= '';
$html .= '자동등록방지 ';
- $html .= ' ';
- $html .= ' ';
+ $html .= ' ';
+ $html .= ' ';
$html .= ' ';
$html .= '자동등록방지 숫자를 순서대로 입력하세요.
';
$html .= ' ';
diff --git a/bbs/gcaptcha/wav.php b/bbs/gcaptcha/wav.php
deleted file mode 100644
index f45405a9e..000000000
--- a/bbs/gcaptcha/wav.php
+++ /dev/null
@@ -1,74 +0,0 @@
- 16){
- $header .= fread($fp,($info['Subchunk1Size']-16));
- }
-
- // read SubChunk2ID
- $header .= fread($fp,4);
-
- // read Subchunk2Size
- $size = unpack('vsize',fread($fp, 4));
- $size = $size['size'];
-
- // read data
- $data .= fread($fp,$size);
- }
-
- return ''
- .pack('a4', 'RIFF')
- .pack('V', strlen($data) + 36)
- .pack('a4', 'WAVE')
- .pack('a4', 'fmt ')
- .pack('V', $info['Subchunk1Size']) // 16
- .pack('v', $info['AudioFormat']) // 1
- .pack('v', $info['NumChannels']) // 1
- .pack('V', $info['SampleRate']) // 8000
- .pack('V', $info['ByteRate']) // 8000
- .pack('v', $info['BlockAlign']) // 1
- .pack('v', $info['BitsPerSample']) // 8
- .pack('a4', 'data')
- .pack('V', strlen($data))
- .$data;
-}
-?>
diff --git a/bbs/member_email_check.php b/bbs/member_email_check.php
deleted file mode 100644
index e9a796500..000000000
--- a/bbs/member_email_check.php
+++ /dev/null
@@ -1,45 +0,0 @@
-
-include_once('./_common.php');
-
-$g4['title'] = 'E-mail 중복확인';
-include_once(G4_PATH.'/head.sub.php');
-
-$mb_email = trim($mb_email);
-
-if ($member[mb_id]) // 수정중 중복확인이면
- $sql = " select mb_email from {$g4[member_table]} where mb_email = '{$mb_email}' and mb_id <> '{$member[mb_id]}' ";
-else
- $sql = " select mb_email from {$g4[member_table]} where mb_email = '{$mb_email}' ";
-$row = sql_fetch($sql);
-
-if ($row[mb_email]) {
- echo <<
- alert(''.$mb_email.'은(는) 이미 다른 회원이 사용하는 E-mail이므로 사용하실 수 없습니다.');
- //opener.fmbform.mb_email_enabled.value = "0"; // 새창으로 열 경우에...
- parent.document.getElementById('mb_email_enabled').value = -1;
- window.close();
-
-HEREDOC;
-} else {
- if (!preg_match("/([0-9a-zA-Z_-]+)@([0-9a-zA-Z_-]+)\.([0-9a-zA-Z_-]+)/", $mb_email)) {
- echo <<
- alert(''.$mb_email.'은(는) E-mail 주소 형식이 아니므로 사용하실 수 없습니다.');
- parent.document.getElementById('mb_email_enabled').value = '';
- window.close();
-
-HEREDOC;
- } else {
- echo <<
- alert(''.$mb_email.'은(는) 중복된 E-mail이 없습니다.'.PHP_EOL.PHP_EOL.'사용하셔도 좋습니다.');
- parent.document.getElementById('mb_email_enabled').value = 1;
- window.close();
-
-HEREDOC;
- }
-}
-
-include_once(G4_PATH.'/tail.sub.php');
-?>
\ No newline at end of file
diff --git a/bbs/member_id_check.php b/bbs/member_id_check.php
deleted file mode 100644
index 96362466e..000000000
--- a/bbs/member_id_check.php
+++ /dev/null
@@ -1,39 +0,0 @@
-
-include_once('./_common.php');
-
-$g4['title'] = '회원아이디 중복확인';
-include_once(G4_PATH.'/head.sub.php');
-
-$mb_id = trim($mb_id);
-
-$mb = get_member($mb_id);
-if ($mb[mb_id]) {
-?>
- ';
-
-} else {
- if (preg_match("/[\,]?{$mb_id}/i", $config[cf_prohibit_id])) {
-?>
- ';
-
- } else {
-?>
- ';
-
- }
-}
-
-include_once(G4_PATH.'/tail.sub.php');
-?>
\ No newline at end of file
diff --git a/bbs/member_nick_check.php b/bbs/member_nick_check.php
deleted file mode 100644
index db5e86321..000000000
--- a/bbs/member_nick_check.php
+++ /dev/null
@@ -1,51 +0,0 @@
-
-include_once('./_common.php');
-
-$g4['title'] = '별명 중복확인';
-include_once(G4_PATH.'/head.sub.php');
-
-$mb_nick = trim($mb_nick);
-
-// 별명은 한글, 영문, 숫자만 가능
-if (!check_string($mb_nick, _G4_HANGUL_ + _G4_ALPHABETIC_ + _G4_NUMERIC_)) {
-?>
-
-
- exit;
-}
-
-$mb = sql_fetch(" select mb_nick from $g4[member_table] where mb_nick = '$mb_nick' ");
-if ($mb[mb_nick]) {
-?>
-
-
-} else {
- if (preg_match("/[\,]?{$mb_nick}/i", $config[cf_prohibit_id])) {
-?>
-
-
- } else {
-?>
-
-
- }
-}
-
-include_once(G4_PATH.'/tail.sub.php');
-?>
\ No newline at end of file
diff --git a/bbs/memo_form.php b/bbs/memo_form.php
index be6b4c4a6..eb60c03fa 100644
--- a/bbs/memo_form.php
+++ b/bbs/memo_form.php
@@ -5,16 +5,16 @@ include_once(G4_GCAPTCHA_PATH.'/gcaptcha.lib.php');
if ($is_guest)
alert_close('회원만 이용하실 수 있습니다.');
-if (!$member['mb_open'] && $is_admin != 'super' && $member['mb_id'] != $mb_id)
+if (!$member['mb_open'] && $is_admin != 'super' && $member['mb_id'] != $mb_id)
alert_close("자신의 정보를 공개하지 않으면 다른분에게 쪽지를 보낼 수 없습니다. 정보공개 설정은 회원정보수정에서 하실 수 있습니다.");
$content = "";
// 탈퇴한 회원에게 쪽지 보낼 수 없음
-if ($me_recv_mb_id)
+if ($me_recv_mb_id)
{
$mb = get_member($me_recv_mb_id);
if (!$mb['mb_id'])
- alert_close('회원정보가 존재하지 않습니다.'.PHP_EOL.PHP_EOL.'탈퇴하였을 수 있습니다.');
+ alert_close('회원정보가 존재하지 않습니다.\\n\\n탈퇴하였을 수 있습니다.');
if (!$mb['mb_open'] && $is_admin != 'super')
alert_close('정보공개를 하지 않았습니다.');
@@ -23,10 +23,10 @@ if ($me_recv_mb_id)
$row = sql_fetch(" select me_memo from {$g4['memo_table']} where me_id = '{$me_id}' and (me_recv_mb_id = '{$member['mb_id']}' or me_send_mb_id = '{$member['mb_id']}') ");
if ($row['me_memo'])
{
- $content = PHP_EOL.PHP_EOL.PHP_EOL.' >'
- .PHP_EOL.' >'
- .PHP_EOL.' >'.preg_replace("/\n/", "\n> ", get_text($row[me_memo], 0))
- .PHP_EOL.' >'
+ $content = "\n\n\n".' >'
+ ."\n".' >'
+ ."\n".' >'.preg_replace("/\n/", "\n> ", get_text($row['me_memo'], 0))
+ ."\n".' >'
.' >';
}
diff --git a/bbs/move_update.php b/bbs/move_update.php
index ac844ec94..e58020d48 100644
--- a/bbs/move_update.php
+++ b/bbs/move_update.php
@@ -43,7 +43,7 @@ while ($row = sql_fetch_array($result))
{
$nick = cut_str($member['mb_nick'], $config['cf_cut_name']);
if (!$row2['wr_is_comment'] && $config['cf_use_copy_log'])
- $row2['wr_content'] .= PHP_EOL.'[이 게시물은 '.$nick.'님에 의해 '.G4_TIME_YMDHIS.' '.$board['bo_subject'].'에서 '.($sw == 'copy' ? '복사' : '이동').' 됨]
';
+ $row2['wr_content'] .= "\n".'[이 게시물은 '.$nick.'님에 의해 '.G4_TIME_YMDHIS.' '.$board['bo_subject'].'에서 '.($sw == 'copy' ? '복사' : '이동').' 됨]
';
$sql = " insert into $move_write_table
set wr_num = '$next_wr_num',
diff --git a/bbs/view_comment.php b/bbs/view_comment.php
index 682fc56a9..2c84f8f39 100644
--- a/bbs/view_comment.php
+++ b/bbs/view_comment.php
@@ -114,7 +114,7 @@ else
include_once($board_skin_path.'/view_comment.skin.php');
if (!$member['mb_id']) // 비회원일 경우에만
- echo ''.PHP_EOL;
+ echo ''."\n";
@include_once($board_skin_path.'/view_comment.tail.skin.php');
?>
\ No newline at end of file
diff --git a/bbs/write_comment_update.php b/bbs/write_comment_update.php
index 754b85371..3b818daf7 100644
--- a/bbs/write_comment_update.php
+++ b/bbs/write_comment_update.php
@@ -67,7 +67,7 @@ if ($w == 'c') // 댓글 입력
{
/*
if ($member[mb_point] + $board[bo_comment_point] < 0 && !$is_admin)
- alert('보유하신 포인트('.number_format($member[mb_point]).')가 없거나 모자라서 댓글쓰기('.number_format($board[bo_comment_point]).')가 불가합니다.'.PHP_EOL.PHP_EOL.'포인트를 적립하신 후 다시 댓글를 써 주십시오.');
+ alert('보유하신 포인트('.number_format($member[mb_point]).')가 없거나 모자라서 댓글쓰기('.number_format($board[bo_comment_point]).')가 불가합니다.\\n\\n포인트를 적립하신 후 다시 댓글를 써 주십시오.');
*/
// 댓글쓰기 포인트설정시 회원의 포인트가 음수인 경우 댓글를 쓰지 못하던 버그를 수정 (곱슬최씨님)
$tmp_point = ($member['mb_point'] > 0) ? $member['mb_point'] : 0;
diff --git a/bbs/write_update.php b/bbs/write_update.php
index 57f4fae6b..4f8ea92f3 100644
--- a/bbs/write_update.php
+++ b/bbs/write_update.php
@@ -349,7 +349,7 @@ if ($w == '' || $w == 'r') {
// 쓰기 포인트 부여
if ($w == '') {
if ($notice) {
- $bo_notice = $wr_id.PHP_EOL.$board['bo_notice'];
+ $bo_notice = $wr_id."\n".$board['bo_notice'];
sql_query(" update {$g4['board_table']} set bo_notice = '{$bo_notice}' where bo_table = '{$bo_table}' ");
}
diff --git a/test.php b/test.php
index f4ccb9dae..30b07f815 100644
--- a/test.php
+++ b/test.php
@@ -1,12 +1 @@
-
-echo a(2);
-
-function a($b)
-{
- global $x;
-
- echo $x+$b;
-}
-
-$x = 1;
-?>
\ No newline at end of file
+
\ No newline at end of file