aboutsummaryrefslogtreecommitdiffstats
path: root/includes/SearchUpdate.php
diff options
context:
space:
mode:
authornobody <nobody@localhost>2004-06-27 00:05:32 +0000
committernobody <nobody@localhost>2004-06-27 00:05:32 +0000
commit0c1d741ff4792d486258b390cf50cf3f9e229511 (patch)
tree55961c46b433ade0739763bee2ba3c4843d13751 /includes/SearchUpdate.php
parentd5c8171a3157337557bc54ecb730d7dd35778ca3 (diff)
parent1aaed5fd7c7f4d7ea7abbfc7915bab5954d60a30 (diff)
downloadmediawikicore-1.3.0beta4a.tar.gz
mediawikicore-1.3.0beta4a.zip
This commit was manufactured by cvs2svn to create tag1.3.0beta4a
'REL1_3_0beta4a'.
Diffstat (limited to 'includes/SearchUpdate.php')
-rw-r--r--includes/SearchUpdate.php8
1 files changed, 5 insertions, 3 deletions
diff --git a/includes/SearchUpdate.php b/includes/SearchUpdate.php
index 08f66eab88ed..c7b9c6103c32 100644
--- a/includes/SearchUpdate.php
+++ b/includes/SearchUpdate.php
@@ -1,4 +1,5 @@
<?php
+# $Id$
# See deferred.doc
class SearchUpdate {
@@ -24,7 +25,7 @@ class SearchUpdate {
function doUpdate()
{
- global $wgDBminWordLen, $wgLang, $wgDisableSearchUpdate;
+ global $wgDBminWordLen, $wgLang, $wgDisableSearchUpdate, $wgIsMySQL;
if( $wgDisableSearchUpdate || !$this->mId ) {
return false;
@@ -32,7 +33,8 @@ class SearchUpdate {
$lc = SearchEngine::legalSearchChars() . "&#;";
if( $this->mText == false ) {
# Just update the title
- $sql = "UPDATE LOW_PRIORITY searchindex SET si_title='" .
+ $lowpri=$wgIsMySQL?"LOW_PRIORITY":"";
+ $sql = "UPDATE $lowpri searchindex SET si_title='" .
wfStrencode( Title::indexTitle( $this->mNamespace, $this->mTitle ) ) .
"' WHERE si_page={$this->mId}";
wfQuery( $sql, DB_WRITE, "SearchUpdate::doUpdate" );
@@ -75,7 +77,7 @@ class SearchUpdate {
# Strip wiki '' and '''
$text = preg_replace( "/''[']*/", " ", $text );
- $sql = "REPLACE DELAYED INTO searchindex (si_page,si_title,si_text) VALUES ({$this->mId},'" .
+ $sql = "REPLACE INTO searchindex (si_page,si_title,si_text) VALUES ({$this->mId},'" .
wfStrencode( Title::indexTitle( $this->mNamespace, $this->mTitle ) ) . "','" .
wfStrencode( $text ) . "')";
wfQuery( $sql, DB_WRITE, "SearchUpdate::doUpdate" );