From eb803ae9c96f93708d64ef6305f0865c706fd527 Mon Sep 17 00:00:00 2001 From: thisgun Date: Mon, 18 Mar 2019 16:19:11 +0900 Subject: [PATCH] =?UTF-8?q?hook=20=ED=95=A8=EC=88=98=EB=AA=85=20=EC=88=98?= =?UTF-8?q?=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- adm/board_form_update.php | 2 +- adm/config_form_update.php | 2 +- adm/dbupgrade.php | 2 +- adm/member_form_update.php | 2 +- adm/member_list_update.php | 2 +- bbs/delete.php | 2 +- bbs/delete_all.php | 2 +- bbs/delete_comment.php | 2 +- bbs/login.php | 2 +- bbs/login_check.php | 4 ++-- bbs/logout.php | 2 +- bbs/memo.php | 2 +- bbs/memo_delete.php | 2 +- bbs/memo_form_update.php | 6 +++--- bbs/move.php | 2 +- bbs/move_update.php | 2 +- bbs/new_delete.php | 2 +- bbs/password_check.php | 4 ++-- bbs/qawrite_update.php | 2 +- bbs/register_form_update.php | 20 ++++++++++---------- bbs/write.php | 2 +- bbs/write_comment_update.php | 2 +- bbs/write_update.php | 12 ++++++------ common.php | 2 +- extend/debugbar.extend.php | 2 +- extend/g5_54version_update.extend.php | 4 ++-- lib/URI/uri.class.php | 4 ++-- lib/cache.lib.php | 2 +- lib/common.lib.php | 18 +++++++++--------- lib/get_data.lib.php | 20 ++++++++++---------- lib/hook.lib.php | 8 ++++---- lib/uri.lib.php | 12 ++++++------ tail.sub.php | 2 +- theme/54/tail.sub.php | 2 +- theme/basic/tail.sub.php | 2 +- 35 files changed, 80 insertions(+), 80 deletions(-) diff --git a/adm/board_form_update.php b/adm/board_form_update.php index c2396ebb2..01a21fe97 100644 --- a/adm/board_form_update.php +++ b/adm/board_form_update.php @@ -446,7 +446,7 @@ delete_cache_latest($bo_table); if(function_exists('get_admin_captcha_by')) get_admin_captcha_by('remove'); -start_event('admin_board_form_update', $bo_table, $w); +run_event('admin_board_form_update', $bo_table, $w); goto_url("./board_form.php?w=u&bo_table={$bo_table}&{$qstr}"); ?> diff --git a/adm/config_form_update.php b/adm/config_form_update.php index fa49b6ea5..c8aff3bd9 100644 --- a/adm/config_form_update.php +++ b/adm/config_form_update.php @@ -192,7 +192,7 @@ if( isset($_POST['cf_bbs_rewrite']) ){ g5_delete_all_cache(); } -start_event('admin_config_form_update'); +run_event('admin_config_form_update'); update_rewrite_rules(); diff --git a/adm/dbupgrade.php b/adm/dbupgrade.php index 52f94bd30..771d3214e 100644 --- a/adm/dbupgrade.php +++ b/adm/dbupgrade.php @@ -147,7 +147,7 @@ if(!isset($member['mb_memo_cnt'])) { $is_check = true; } -$is_check = apply_replace('admin_dbupgrade', $is_check); +$is_check = run_replace('admin_dbupgrade', $is_check); $db_upgrade_msg = $is_check ? 'DB 업그레이드가 완료되었습니다.' : '더 이상 업그레이드 할 내용이 없습니다.
현재 DB 업그레이드가 완료된 상태입니다.'; ?> diff --git a/adm/member_form_update.php b/adm/member_form_update.php index e124ec6d6..89824f0a1 100644 --- a/adm/member_form_update.php +++ b/adm/member_form_update.php @@ -233,7 +233,7 @@ else if ($w == 'u') else alert('제대로 된 값이 넘어오지 않았습니다.'); -start_event('admin_member_form_update', $w, $mb_id); +run_event('admin_member_form_update', $w, $mb_id); goto_url('./member_form.php?'.$qstr.'&w=u&mb_id='.$mb_id, false); ?> \ No newline at end of file diff --git a/adm/member_list_update.php b/adm/member_list_update.php index 85b5efc53..7e250d4af 100644 --- a/adm/member_list_update.php +++ b/adm/member_list_update.php @@ -76,7 +76,7 @@ if ($msg) //echo ''; alert($msg); -start_event('admin_member_list_update', $_POST['act_button'], $mb_datas); +run_event('admin_member_list_update', $_POST['act_button'], $mb_datas); goto_url('./member_list.php?'.$qstr); ?> diff --git a/bbs/delete.php b/bbs/delete.php index 3f279e4fb..81690c3c2 100644 --- a/bbs/delete.php +++ b/bbs/delete.php @@ -134,7 +134,7 @@ if ($count_write > 0 || $count_comment > 0) delete_cache_latest($bo_table); -start_event('bbs_delete', $write, $board); +run_event('bbs_delete', $write, $board); goto_url(short_url_clean(G5_HTTP_BBS_URL.'/board.php?bo_table='.$bo_table.'&page='.$page.$qstr)); ?> diff --git a/bbs/delete_all.php b/bbs/delete_all.php index 13d4793f8..5fa17c855 100644 --- a/bbs/delete_all.php +++ b/bbs/delete_all.php @@ -156,7 +156,7 @@ if ($count_write > 0 || $count_comment > 0) delete_cache_latest($bo_table); -start_event('bbs_delete_all', $tmp_array, $board); +run_event('bbs_delete_all', $tmp_array, $board); goto_url(short_url_clean(G5_HTTP_BBS_URL.'/board.php?bo_table='.$bo_table.'&page='.$page.$qstr)); ?> diff --git a/bbs/delete_comment.php b/bbs/delete_comment.php index 11e08715d..76d9df224 100644 --- a/bbs/delete_comment.php +++ b/bbs/delete_comment.php @@ -86,7 +86,7 @@ sql_query(" delete from {$g5['board_new_table']} where bo_table = '{$bo_table}' delete_cache_latest($bo_table); -start_event('bbs_delete_comment', $comment_id, $board); +run_event('bbs_delete_comment', $comment_id, $board); goto_url(G5_HTTP_BBS_URL.'/board.php?bo_table='.$bo_table.'&wr_id='.$write['wr_parent'].'&page='.$page. $qstr); ?> diff --git a/bbs/login.php b/bbs/login.php index 90f593ac1..3cb6c0863 100644 --- a/bbs/login.php +++ b/bbs/login.php @@ -31,7 +31,7 @@ if (!file_exists($login_file)) include_once($member_skin_path.'/login.skin.php'); -start_event('member_login_tail', $login_url, $login_action_url, $member_skin_path, $url); +run_event('member_login_tail', $login_url, $login_action_url, $member_skin_path, $url); include_once('./_tail.sub.php'); ?> diff --git a/bbs/login_check.php b/bbs/login_check.php index 07fa4da78..614732d32 100644 --- a/bbs/login_check.php +++ b/bbs/login_check.php @@ -31,7 +31,7 @@ if(function_exists('social_is_login_check')){ // 불법사용자의 경우 회원아이디가 틀린지, 비밀번호가 틀린지를 알기까지는 많은 시간이 소요되기 때문입니다. if (!$is_social_password_check && (!$mb['mb_id'] || !login_password_check($mb, $mb_password, $mb['mb_password'])) ) { - start_event('password_is_wrong', 'login', $mb); + run_event('password_is_wrong', 'login', $mb); alert('가입된 회원아이디가 아니거나 비밀번호가 틀립니다.\\n비밀번호는 대소문자를 구분합니다.'); } @@ -121,7 +121,7 @@ if(function_exists('social_login_success_after')){ social_login_session_clear(1); } -start_event('member_login_check', $mb, $link); +run_event('member_login_check', $mb, $link); goto_url($link); ?> diff --git a/bbs/logout.php b/bbs/logout.php index 5925e967b..68c49c78b 100644 --- a/bbs/logout.php +++ b/bbs/logout.php @@ -34,7 +34,7 @@ if ($url) { $link = G5_URL; } -start_event('member_logout', $link); +run_event('member_logout', $link); goto_url($link); ?> diff --git a/bbs/memo.php b/bbs/memo.php index 8cd7d85fd..7de13908b 100644 --- a/bbs/memo.php +++ b/bbs/memo.php @@ -20,7 +20,7 @@ else if ($page < 1) { $page = 1; } // 페이지가 없으면 첫 페이지 (1 페이지) -start_event('memo_list', $kind, $unkind, $page); +run_event('memo_list', $kind, $unkind, $page); $sql = " select count(*) as cnt from {$g5['memo_table']} where me_{$kind}_mb_id = '{$member['mb_id']}' and me_type = '$kind' "; $row = sql_fetch($sql); diff --git a/bbs/memo_delete.php b/bbs/memo_delete.php index 6a46cc862..4d5278e59 100644 --- a/bbs/memo_delete.php +++ b/bbs/memo_delete.php @@ -32,7 +32,7 @@ if (!$row['me_read_datetime'][0]) // 메모 받기전이면 sql_query($sql); } -start_event('memo_delete', $me_id, $row); +run_event('memo_delete', $me_id, $row); goto_url('./memo.php?kind='.$kind); ?> diff --git a/bbs/memo_form_update.php b/bbs/memo_form_update.php index 7fa950efc..167f91a4b 100644 --- a/bbs/memo_form_update.php +++ b/bbs/memo_form_update.php @@ -15,7 +15,7 @@ $msg = ''; $error_list = array(); $member_list = array('id'=>array(), 'nick'=>array()); -start_event('memo_form_update_before', $recv_list); +run_event('memo_form_update_before', $recv_list); for ($i=0; $i diff --git a/bbs/move_update.php b/bbs/move_update.php index ae91f1365..c1fdfbc17 100644 --- a/bbs/move_update.php +++ b/bbs/move_update.php @@ -212,7 +212,7 @@ $msg = '해당 게시물을 선택한 게시판으로 '.$act.' 하였습니다.' $opener_href = get_pretty_url($bo_table,'','&page='.$page.'&'.$qstr); $opener_href1 = str_replace('&', '&', $opener_href); -start_event('bbs_move_update', $bo_table, $chk_bo_table, $wr_id_list, $opener_href); +run_event('bbs_move_update', $bo_table, $chk_bo_table, $wr_id_list, $opener_href); echo << diff --git a/bbs/new_delete.php b/bbs/new_delete.php index 35d6601f6..8fa4c8416 100644 --- a/bbs/new_delete.php +++ b/bbs/new_delete.php @@ -143,7 +143,7 @@ foreach ($save_bo_table as $key=>$value) { delete_cache_latest($value); } -start_event('bbs_new_delete', $chk_bn_id, $save_bo_table); +run_event('bbs_new_delete', $chk_bn_id, $save_bo_table); goto_url("new.php?sfl=$sfl&stx=$stx&page=$page"); ?> \ No newline at end of file diff --git a/bbs/password_check.php b/bbs/password_check.php index 01292b017..0304a557d 100644 --- a/bbs/password_check.php +++ b/bbs/password_check.php @@ -13,7 +13,7 @@ if ($w == 's') { } if (!check_password($wr_password, $wr['wr_password'])) { - start_event('password_is_wrong', 'bbs', $wr); + run_event('password_is_wrong', 'bbs', $wr); alert('비밀번호가 틀립니다.'); } @@ -35,7 +35,7 @@ if ($w == 's') { } if (!check_password($wr_password, $wr['wr_password'])){ - start_event('password_is_wrong', 'bbs', $wr); + run_event('password_is_wrong', 'bbs', $wr); alert('비밀번호가 틀립니다.'); } diff --git a/bbs/qawrite_update.php b/bbs/qawrite_update.php index 654b5772f..f94e613e6 100644 --- a/bbs/qawrite_update.php +++ b/bbs/qawrite_update.php @@ -317,7 +317,7 @@ if($w == '' || $w == 'a' || $w == 'r') { sql_query($sql); } -start_event('qawrite_update', $qa_id, $write, $w, $qaconfig); +run_event('qawrite_update', $qa_id, $write, $w, $qaconfig); // SMS 알림 if($config['cf_sms_use'] == 'icode' && $qaconfig['qa_use_sms']) { diff --git a/bbs/register_form_update.php b/bbs/register_form_update.php index 8f79a566c..c68a33687 100644 --- a/bbs/register_form_update.php +++ b/bbs/register_form_update.php @@ -74,7 +74,7 @@ $mb_addr2 = clean_xss_tags($mb_addr2); $mb_addr3 = clean_xss_tags($mb_addr3); $mb_addr_jibeon = preg_match("/^(N|R)$/", $mb_addr_jibeon) ? $mb_addr_jibeon : ''; -start_event('register_form_update_before', $mb_id, $w); +run_event('register_form_update_before', $mb_id, $w); if ($w == '' || $w == 'u') { @@ -148,7 +148,7 @@ if ($w == '' || $w == 'u') { $old_email = $member['mb_email']; } - start_event('register_form_update_valid', $w, $mb_id, $mb_nick, $mb_email); + run_event('register_form_update_valid', $w, $mb_id, $mb_nick, $mb_email); if ($msg = exist_mb_nick($mb_nick, $mb_id)) alert($msg, "", true, true); if ($msg = exist_mb_email($mb_email, $mb_id)) alert($msg, "", true, true); @@ -270,11 +270,11 @@ if ($w == '') { $content = ob_get_contents(); ob_end_clean(); - $content = apply_replace('register_form_update_mail_mb_content', $content, $mb_id); + $content = run_replace('register_form_update_mail_mb_content', $content, $mb_id); mailer($config['cf_admin_email_name'], $config['cf_admin_email'], $mb_email, $subject, $content, 1); - start_event('register_form_update_send_mb_mail', $config['cf_admin_email_name'], $config['cf_admin_email'], $mb_email, $subject, $content); + run_event('register_form_update_send_mb_mail', $config['cf_admin_email_name'], $config['cf_admin_email'], $mb_email, $subject, $content); // 메일인증을 사용하는 경우 가입메일에 인증 url이 있으므로 인증메일을 다시 발송되지 않도록 함 if($config['cf_use_email_certify']) @@ -283,18 +283,18 @@ if ($w == '') { // 최고관리자님께 메일 발송 if ($config['cf_email_mb_super_admin']) { - $subject = apply_replace('register_form_update_mail_admin_subject', '['.$config['cf_title'].'] '.$mb_nick .' 님께서 회원으로 가입하셨습니다.', $mb_id, $mb_nick); + $subject = run_replace('register_form_update_mail_admin_subject', '['.$config['cf_title'].'] '.$mb_nick .' 님께서 회원으로 가입하셨습니다.', $mb_id, $mb_nick); ob_start(); include_once ('./register_form_update_mail2.php'); $content = ob_get_contents(); ob_end_clean(); - $content = apply_replace('register_form_update_mail_admin_content', $content, $mb_id); + $content = run_replace('register_form_update_mail_admin_content', $content, $mb_id); mailer($mb_nick, $mb_email, $config['cf_admin_email'], $subject, $content, 1); - start_event('register_form_update_send_admin_mail', $mb_nick, $mb_email, $config['cf_admin_email'], $subject, $content); + run_event('register_form_update_send_admin_mail', $mb_nick, $mb_email, $config['cf_admin_email'], $subject, $content); } // 메일인증 사용하지 않는 경우에만 로그인 @@ -497,11 +497,11 @@ if ($config['cf_use_email_certify'] && $old_email != $mb_email) { $content = ob_get_contents(); ob_end_clean(); - $content = apply_replace('register_form_update_mail_certify_content', $content, $mb_id); + $content = run_replace('register_form_update_mail_certify_content', $content, $mb_id); mailer($config['cf_admin_email_name'], $config['cf_admin_email'], $mb_email, $subject, $content, 1); - start_event('register_form_update_send_certify_mail', $config['cf_admin_email_name'], $config['cf_admin_email'], $mb_email, $subject, $content); + run_event('register_form_update_send_certify_mail', $config['cf_admin_email_name'], $config['cf_admin_email'], $mb_email, $subject, $content); } @@ -517,7 +517,7 @@ unset($_SESSION['ss_cert_adult']); if ($msg) echo ''; -start_event('register_form_update_after', $mb_id, $w); +run_event('register_form_update_after', $mb_id, $w); if ($w == '') { goto_url(G5_HTTP_BBS_URL.'/register_result.php'); diff --git a/bbs/write.php b/bbs/write.php index fe12c12f1..929d6c226 100644 --- a/bbs/write.php +++ b/bbs/write.php @@ -31,7 +31,7 @@ if ($w == 'u' || $w == 'r') { } } -start_event('bbs_write', $board, $wr_id, $w); +run_event('bbs_write', $board, $wr_id, $w); if ($w == '') { if ($wr_id) { diff --git a/bbs/write_comment_update.php b/bbs/write_comment_update.php index ea02128a6..b99a4ac7c 100644 --- a/bbs/write_comment_update.php +++ b/bbs/write_comment_update.php @@ -341,7 +341,7 @@ delete_cache_latest($bo_table); $redirect_url = short_url_clean(G5_HTTP_BBS_URL.'/board.php?bo_table='.$bo_table.'&wr_id='.$wr['wr_parent'].'&'.$qstr.'&#c_'.$comment_id); -start_event('comment_update_after', $board, $wr_id, $w, $qstr, $redirect_url); +run_event('comment_update_after', $board, $wr_id, $w, $qstr, $redirect_url); goto_url($redirect_url); ?> diff --git a/bbs/write_update.php b/bbs/write_update.php index 3822ff888..358c8ebc3 100644 --- a/bbs/write_update.php +++ b/bbs/write_update.php @@ -127,7 +127,7 @@ for ($i=1; $i<=10; $i++) { @include_once($board_skin_path.'/write_update.head.skin.php'); -start_event('write_update_before', $board, $wr_id, $w, $qstr); +run_event('write_update_before', $board, $wr_id, $w, $qstr); if ($w == '' || $w == 'u') { @@ -553,7 +553,7 @@ for ($i=0; $i diff --git a/extend/debugbar.extend.php b/extend/debugbar.extend.php index a3f935665..757b9e16e 100644 --- a/extend/debugbar.extend.php +++ b/extend/debugbar.extend.php @@ -1,7 +1,7 @@ ') : '올바른 방법으로 이용해 주십시오.'; @@ -173,7 +173,7 @@ function alert_close($msg, $error=true) { global $g5; - start_event('alert_close', $msg, $error); + run_event('alert_close', $msg, $error); $msg = strip_tags($msg, '
'); @@ -251,7 +251,7 @@ function url_auto_link($str) $str = preg_replace("/\t_gt_\t/", ">", $str); */ - return apply_replace('url_auto_link', $str); + return run_replace('url_auto_link', $str); } @@ -741,7 +741,7 @@ function get_group($gr_id, $is_cache=false) $sql = " select * from {$g5['group_table']} where gr_id = '$gr_id' "; - $cache[$key] = apply_replace('get_group', sql_fetch($sql), $gr_id, $is_cache); + $cache[$key] = run_replace('get_group', sql_fetch($sql), $gr_id, $is_cache); return $cache[$key]; } @@ -764,7 +764,7 @@ function get_member($mb_id, $fields='*', $is_cache=false) $sql = " select $fields from {$g5['member_table']} where mb_id = TRIM('$mb_id') "; - $cache[$mb_id][$key] = apply_replace('get_member', sql_fetch($sql), $mb_id, $fields, $is_cache); + $cache[$mb_id][$key] = run_replace('get_member', sql_fetch($sql), $mb_id, $fields, $is_cache); return $cache[$mb_id][$key]; } @@ -857,7 +857,7 @@ function is_admin($mb_id) $is_authority = 'board'; } - return apply_replace('is_admin', $is_authority, $mb_id); + return run_replace('is_admin', $is_authority, $mb_id); } @@ -2543,7 +2543,7 @@ class html_process { array_multisort($order, SORT_ASC, $index, SORT_ASC, $links); - $links = apply_replace('html_process_css_files', $links); + $links = run_replace('html_process_css_files', $links); foreach($links as $link) { if(!trim($link[1])) @@ -2571,7 +2571,7 @@ class html_process { array_multisort($order, SORT_ASC, $index, SORT_ASC, $scripts); - $scripts = apply_replace('html_process_script_files', $scripts); + $scripts = run_replace('html_process_script_files', $scripts); foreach($scripts as $js) { if(!trim($js[1])) @@ -2789,7 +2789,7 @@ function get_qa_config($fld='*') } $sql = " select * from {$g5['qa_config_table']} "; - $cache = apply_replace('get_qa_config', sql_fetch($sql)); + $cache = run_replace('get_qa_config', sql_fetch($sql)); return $cache; } diff --git a/lib/get_data.lib.php b/lib/get_data.lib.php index b1b22a3fe..eb1c934a1 100644 --- a/lib/get_data.lib.php +++ b/lib/get_data.lib.php @@ -6,14 +6,14 @@ function get_config($is_cache=false){ static $cache = array(); - $cache = apply_replace('get_config_cache', $cache, $is_cache); + $cache = run_replace('get_config_cache', $cache, $is_cache); if( $is_cache && !empty($cache) ){ return $cache; } $sql = " select * from {$g5['config_table']} "; - $cache = apply_replace('get_config', sql_fetch($sql)); + $cache = run_replace('get_config', sql_fetch($sql)); return $cache; } @@ -68,7 +68,7 @@ function get_board_db($bo_table, $is_cache=false){ static $cache = array(); - $cache = apply_replace('get_board_db_cache', $cache, $bo_table, $is_cache); + $cache = run_replace('get_board_db_cache', $cache, $bo_table, $is_cache); $key = md5($bo_table); @@ -77,7 +77,7 @@ function get_board_db($bo_table, $is_cache=false){ return $cache[$key]; } - if( !($cache[$key] = apply_replace('get_board_db', array(), $bo_table)) ){ + if( !($cache[$key] = run_replace('get_board_db', array(), $bo_table)) ){ $sql = " select * from {$g5['board_table']} where bo_table = '$bo_table' "; @@ -259,7 +259,7 @@ function get_db_charset($charset){ $add_charset .= ' COLLATE utf8mb4_unicode_ci'; } - return apply_replace('get_db_charset', $add_charset, $charset); + return run_replace('get_db_charset', $add_charset, $charset); } function get_db_create_replace($sql_str){ @@ -284,7 +284,7 @@ function get_class_encrypt(){ return $cache; } - $cache = apply_replace('get_class_encrypt', new str_encrypt()); + $cache = run_replace('get_class_encrypt', new str_encrypt()); return $cache; } @@ -315,7 +315,7 @@ function get_permission_debug_show(){ $bool = true; } - return apply_replace('get_permission_debug_show', $bool, $member); + return run_replace('get_permission_debug_show', $bool, $member); } function get_check_mod_rewrite(){ @@ -332,7 +332,7 @@ function get_check_mod_rewrite(){ function get_mb_icon_name($mb_id){ - if( $icon_name = apply_replace('get_mb_icon_name', '', $mb_id) ){ + if( $icon_name = run_replace('get_mb_icon_name', '', $mb_id) ){ return $icon_name; } @@ -348,7 +348,7 @@ function get_bo_table_banned_word(){ $folders[] = basename($dir); } - return apply_replace('get_bo_table_banned_word', $folders); + return run_replace('get_bo_table_banned_word', $folders); } function get_board_sfl_select_options($sfl){ @@ -366,7 +366,7 @@ function get_board_sfl_select_options($sfl){ $str .= ''; $str .= ''; - return apply_replace('get_board_sfl_select_options', $str, $sfl); + return run_replace('get_board_sfl_select_options', $str, $sfl); } // 읽지 않은 메모 갯수 반환 diff --git a/lib/hook.lib.php b/lib/hook.lib.php index b721e981d..453d79a78 100644 --- a/lib/hook.lib.php +++ b/lib/hook.lib.php @@ -28,14 +28,14 @@ function get_hook_class(){ return null; } -function put_event($tag, $func, $priority=G5_HOOK_DEFAULT_PRIORITY, $args=0){ +function add_event($tag, $func, $priority=G5_HOOK_DEFAULT_PRIORITY, $args=0){ if( $hook = get_hook_class() ){ $hook->addAction($tag, $func, $priority, $args); } } -function start_event($tag, $arg = ''){ +function run_event($tag, $arg = ''){ if( $hook = get_hook_class() ){ @@ -65,7 +65,7 @@ function start_event($tag, $arg = ''){ } } -function put_replace($tag, $func, $priority=G5_HOOK_DEFAULT_PRIORITY, $args=0){ +function add_replace($tag, $func, $priority=G5_HOOK_DEFAULT_PRIORITY, $args=0){ if( $hook = get_hook_class() ){ return $hook->addFilter($tag, $func, $priority, $args); @@ -74,7 +74,7 @@ function put_replace($tag, $func, $priority=G5_HOOK_DEFAULT_PRIORITY, $args=0){ return null; } -function apply_replace($tag, $arg = ''){ +function run_replace($tag, $arg = ''){ if( $hook = get_hook_class() ){ diff --git a/lib/uri.lib.php b/lib/uri.lib.php index 23ef9bc98..7a6e1c20f 100644 --- a/lib/uri.lib.php +++ b/lib/uri.lib.php @@ -13,7 +13,7 @@ function get_pretty_url($folder, $no='', $query_string='', $action='') $segments = array(); $url = $add_query = ''; - if( $url = apply_replace('get_pretty_url', $url, $folder, $no, $query_string, $action) ){ + if( $url = run_replace('get_pretty_url', $url, $folder, $no, $query_string, $action) ){ return $url; } @@ -108,7 +108,7 @@ function short_url_clean($string_url, $add_qry=''){ $url=parse_url($string_url); $page_name = basename($url['path'],".php"); - $array_page_names = apply_replace('url_clean_page_names', array('board', 'write')); + $array_page_names = run_replace('url_clean_page_names', array('board', 'write')); if( strpos($string_url, G5_BBS_URL) === false || ! in_array($page_name, $array_page_names) ){ //게시판이 아니면 리턴 return $string_url; @@ -150,7 +150,7 @@ function short_url_clean($string_url, $add_qry=''){ if( isset($url['host']) ){ - $array_file_paths = apply_replace('url_clean_page_paths', array('/'.G5_BBS_DIR.'/board.php', '/'.G5_BBS_DIR.'/write.php')); + $array_file_paths = run_replace('url_clean_page_paths', array('/'.G5_BBS_DIR.'/board.php', '/'.G5_BBS_DIR.'/write.php')); $str_path = isset($url['path']) ? $url['path'] : ''; $http = (isset($_SERVER['HTTPS']) && $_SERVER['HTTPS']=='on') ? 'https://' : 'http://'; @@ -231,7 +231,7 @@ function exist_seo_url($type, $seo_title, $write_table, $sql_id=0){ $exists_title = $row['co_seo_title']; } else { - return apply_replace('exist_check_seo_title', $seo_title, $type, $write_table, $sql_id); + return run_replace('exist_check_seo_title', $seo_title, $type, $write_table, $sql_id); } if ($exists_title) @@ -296,7 +296,7 @@ function get_nginx_conf_rules($return_string=false){ $rules[] = '#### '.G5_VERSION.' nginx rules BEGIN #####'; $rules[] = 'if (!-e $request_filename){'; - if( $add_rules = apply_replace('add_nginx_conf_rules', '', $get_path_url, $base_path, $return_string) ){ + if( $add_rules = run_replace('add_nginx_conf_rules', '', $get_path_url, $base_path, $return_string) ){ $rules[] = $add_rules; } @@ -329,7 +329,7 @@ function get_mod_rewrite_rules($return_string=false){ $rules[] = 'RewriteCond %{REQUEST_FILENAME} -d'; $rules[] = 'RewriteRule ^ - [L]'; - if( $add_rules = apply_replace('add_mod_rewrite_rules', '', $get_path_url, $base_path, $return_string) ){ + if( $add_rules = run_replace('add_mod_rewrite_rules', '', $get_path_url, $base_path, $return_string) ){ $rules[] = $add_rules; } diff --git a/tail.sub.php b/tail.sub.php index cf859d92f..1d038707b 100644 --- a/tail.sub.php +++ b/tail.sub.php @@ -25,7 +25,7 @@ $(function() { - + diff --git a/theme/54/tail.sub.php b/theme/54/tail.sub.php index 6772a3772..1c25b33cd 100644 --- a/theme/54/tail.sub.php +++ b/theme/54/tail.sub.php @@ -20,7 +20,7 @@ $(function() { - + diff --git a/theme/basic/tail.sub.php b/theme/basic/tail.sub.php index 6772a3772..1c25b33cd 100644 --- a/theme/basic/tail.sub.php +++ b/theme/basic/tail.sub.php @@ -20,7 +20,7 @@ $(function() { - +