mirror of
https://github.com/phpbb/phpbb.git
synced 2025-08-05 16:27:38 +02:00
regex for word splitting on search was failing to pick up on numerals
git-svn-id: file:///svn/phpbb/branches/phpBB-2_0_0@3251 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
@@ -91,7 +91,7 @@ function clean_words($mode, &$entry, &$stopword_list, &$synonym_list)
|
||||
|
||||
function split_words(&$entry, $mode = 'post')
|
||||
{
|
||||
$rex = ( $mode == 'post' ) ? "/\b([\w<EFBFBD><EFBFBD>-<2D>][\w<EFBFBD><EFBFBD>-<2D>']*[\w<EFBFBD><EFBFBD>-<2D>]+|[\w<EFBFBD><EFBFBD>-<2D>]+?)\b/" : '/(\*?[a-z<><7A>-<2D>]+\*?)|\b([a-z<><7A>-<2D>]+)\b/';
|
||||
$rex = ( $mode == 'post' ) ? "/\b([\w<EFBFBD><EFBFBD>-<2D>][\w<EFBFBD><EFBFBD>-<2D>']*[\w<EFBFBD><EFBFBD>-<2D>]+|[\w<EFBFBD><EFBFBD>-<2D>]+?)\b/" : '/(\*?[a-z0-9<EFBFBD><EFBFBD>-<2D>]+\*?)|\b([a-z0-9<EFBFBD><EFBFBD>-<2D>]+)\b/';
|
||||
preg_match_all($rex, $entry, $split_entries);
|
||||
|
||||
return $split_entries[1];
|
||||
|
Reference in New Issue
Block a user