Index: trunk/phase3/includes/SearchMySQL4.php |
— | — | @@ -54,7 +54,7 @@ |
55 | 55 | // Match the quoted term in result highlighting... |
56 | 56 | $regexp = preg_quote( str_replace( '"', '', $terms[2] ), '/' ); |
57 | 57 | } |
58 | | - $this->searchTerms[] = $regexp; |
| 58 | + $this->searchTerms[] = "\b$regexp\b"; |
59 | 59 | } |
60 | 60 | wfDebug( "Would search with '$searchon'\n" ); |
61 | 61 | wfDebug( 'Match with /\b' . implode( '\b|\b', $this->searchTerms ) . "\b/\n" ); |
Index: trunk/phase3/RELEASE-NOTES |
— | — | @@ -79,7 +79,9 @@ |
80 | 80 | * (bug 11462) Fix typo in LanguageGetSpecialPageAliases hook name |
81 | 81 | * (bug 11474) Fix unintentional fall-through in math error handling |
82 | 82 | * (bug 11478) Fix undefined method call in file deletion interface |
| 83 | +* (bug 278) Search results no longer highlight incorrect partial word matches |
83 | 84 | |
| 85 | + |
84 | 86 | === API changes in 1.12 === |
85 | 87 | |
86 | 88 | Full API documentation is available at http://www.mediawiki.org/wiki/API |