From 63c060dbd4305097c671758833a24241cb3f4afd Mon Sep 17 00:00:00 2001 From: Brion Vibber Date: Fri, 10 Dec 2004 03:20:23 +0000 Subject: [PATCH] Fix for table prefix --- includes/SpecialAllmessages.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/includes/SpecialAllmessages.php b/includes/SpecialAllmessages.php index a58f9f0d4d..d1e9c281b3 100644 --- a/includes/SpecialAllmessages.php +++ b/includes/SpecialAllmessages.php @@ -112,9 +112,10 @@ function makeHTMLText( $messages ) { NS_MEDIAWIKI => array(), NS_MEDIAWIKI_TALK => array() ); - $sql = "SELECT cur_namespace,cur_title FROM cur WHERE cur_namespace IN (" . NS_MEDIAWIKI . ", " . NS_MEDIAWIKI_TALK . ")"; $dbr =& wfGetDB( DB_SLAVE ); - $res = $dbr->query( $sql ); + $res = $dbr->select( 'cur', + array( 'cur_namespace', 'cur_title' ), + "cur_namespace IN (" . NS_MEDIAWIKI . ", " . NS_MEDIAWIKI_TALK . ")" ); while( $s = $dbr->fetchObject( $res ) ) { $pageExists[$s->cur_namespace][$s->cur_title] = true; } -- 2.20.1