[問題]2.08a主題名稱過長導致文章失效
版主: 版主管理群
版面規則
本區是討論關於 phpBB 2.0.X 架設安裝上的問題,只要有安裝任何外掛,請到外掛討論相關版面按照公告格式發表。
(發表文章請按照公告格式發表,違者砍文)
本區是討論關於 phpBB 2.0.X 架設安裝上的問題,只要有安裝任何外掛,請到外掛討論相關版面按照公告格式發表。
(發表文章請按照公告格式發表,違者砍文)
步驟1:
修改\r
includes/functions_search.php
第92行將
[php]
function split_words(&$entry, $mode = 'post')
{
// If you experience problems with the new method, uncomment this block.
/*
$rex = ( $mode == 'post' ) ? "/\b([\w接-][\w接-']*[\w接-]+|[\w接-]+?)\b/" : '/(\*?[a-z0-9接-]+\*?)|\b([a-z0-9接-]+)\b/';
preg_match_all($rex, $entry, $split_entries);
return $split_entries[1];
*/
// Trim 1+ spaces to one space and split this trimmed string into words.
return explode(' ', trim(preg_replace('#\s+#', ' ', $entry)));
}
[/php]
改為\r
[php]
function split_words(&$entry, $mode = 'post')
{
// If you experience problems with the new method, uncomment this block.
$rex = ( $mode == 'post' ) ? "/\b([\w接-][\w接-']*[\w接-]+|[\w接-]+?)\b/" : '/(\*?[a-z0-9接-]+\*?)|\b([a-z0-9接-]+)\b/';
preg_match_all($rex, $entry, $split_entries);
return $split_entries[1];
// Trim 1+ spaces to one space and split this trimmed string into words.
return explode(' ', trim(preg_replace('#\s+#', ' ', $entry)));
}
[/php]
改看看~
修改\r
includes/functions_search.php
第92行將
[php]
function split_words(&$entry, $mode = 'post')
{
// If you experience problems with the new method, uncomment this block.
/*
$rex = ( $mode == 'post' ) ? "/\b([\w接-][\w接-']*[\w接-]+|[\w接-]+?)\b/" : '/(\*?[a-z0-9接-]+\*?)|\b([a-z0-9接-]+)\b/';
preg_match_all($rex, $entry, $split_entries);
return $split_entries[1];
*/
// Trim 1+ spaces to one space and split this trimmed string into words.
return explode(' ', trim(preg_replace('#\s+#', ' ', $entry)));
}
[/php]
改為\r
[php]
function split_words(&$entry, $mode = 'post')
{
// If you experience problems with the new method, uncomment this block.
$rex = ( $mode == 'post' ) ? "/\b([\w接-][\w接-']*[\w接-]+|[\w接-]+?)\b/" : '/(\*?[a-z0-9接-]+\*?)|\b([a-z0-9接-]+)\b/';
preg_match_all($rex, $entry, $split_entries);
return $split_entries[1];
// Trim 1+ spaces to one space and split this trimmed string into words.
return explode(' ', trim(preg_replace('#\s+#', ' ', $entry)));
}
[/php]
改看看~

