From cf566e3512e605c7cb5d3e1fd5c3cd03face69b6 Mon Sep 17 00:00:00 2001 From: thisgun Date: Wed, 24 Oct 2018 13:53:44 +0900 Subject: [PATCH] =?UTF-8?q?URL=20=ED=83=80=EC=9D=B4=ED=8B=80=20=EC=A7=80?= =?UTF-8?q?=EC=A0=95=20=EC=BD=94=EB=93=9C=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- adm/dbupgrade.php | 6 ++++-- lib/uri.lib.php | 8 +++----- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/adm/dbupgrade.php b/adm/dbupgrade.php index e3c7e1c73..d61b41b36 100644 --- a/adm/dbupgrade.php +++ b/adm/dbupgrade.php @@ -86,7 +86,7 @@ while ($row = sql_fetch_array($result)) { if( !$row ){ sql_query("ALTER TABLE `{$write_table}` - ADD `wr_seo_title` varchar(255) NOT NULL DEFAULT '' AFTER `wr_content`, + ADD `wr_seo_title` varchar(200) NOT NULL DEFAULT '' AFTER `wr_content`, ADD INDEX `wr_seo_title` (`wr_seo_title`); ", false); @@ -100,7 +100,7 @@ $row = sql_fetch($sql); if( !$row ){ sql_query("ALTER TABLE `{$g5['content_table']}` - ADD `co_seo_title` varchar(255) NOT NULL DEFAULT '' AFTER `co_content`, + ADD `co_seo_title` varchar(200) NOT NULL DEFAULT '' AFTER `co_content`, ADD INDEX `co_seo_title` (`co_seo_title`); ", false); @@ -125,6 +125,8 @@ while ($row = sql_fetch_array($result)) { } +$is_check = apply_replace('admin_dbupgrade', $is_check); + $db_upgrade_msg = $is_check ? 'DB 업그레이드가 완료되었습니다.' : '더 이상 업그레이드 할 내용이 없습니다.
현재 DB 업그레이드가 완료된 상태입니다.'; ?> diff --git a/lib/uri.lib.php b/lib/uri.lib.php index fb7a893f6..cc5d317aa 100644 --- a/lib/uri.lib.php +++ b/lib/uri.lib.php @@ -221,8 +221,6 @@ function exist_seo_url($type, $seo_title, $write_table, $sql_id=0){ $sql = "select wr_seo_title FROM {$write_table} WHERE wr_seo_title = '".sql_real_escape_string($seo_title)."' AND wr_id <> '$sql_id' limit 1"; $row = sql_fetch($sql); - - echo $sql; $exists_title = $row['wr_seo_title']; @@ -234,7 +232,7 @@ function exist_seo_url($type, $seo_title, $write_table, $sql_id=0){ $exists_title = $row['co_seo_title']; } else { - return $seo_title; + return apply_replace('exist_check_seo_title', $seo_title, $type, $write_table, $sql_id); } if ($exists_title) @@ -246,7 +244,7 @@ function exist_seo_url($type, $seo_title, $write_table, $sql_id=0){ function exist_seo_title_recursive($type, $seo_title, $write_table, $sql_id=0){ static $count = 0; - $seo_title_add = ($count > 0) ? utf8_strcut($seo_title, 255 - ($count+1), '')."-$count" : $seo_title; + $seo_title_add = ($count > 0) ? utf8_strcut($seo_title, 200 - ($count+1), '')."-$count" : $seo_title; if( ! exist_seo_url($type, $seo_title_add, $write_table, $sql_id) ){ return $seo_title_add; @@ -254,7 +252,7 @@ function exist_seo_title_recursive($type, $seo_title, $write_table, $sql_id=0){ $count++; - if( $count > 253 ){ + if( $count > 198 ){ return $seo_title_add; }