Index: trunk/extensions/Translate/Translate.php |
— | — | @@ -11,7 +11,7 @@ |
12 | 12 | * @license http://www.gnu.org/copyleft/gpl.html GNU General Public License 2.0 or later |
13 | 13 | */ |
14 | 14 | |
15 | | -define( 'TRANSLATE_VERSION', '9 (2008-07-04:2)' ); |
| 15 | +define( 'TRANSLATE_VERSION', '9 (2008-07-05:1)' ); |
16 | 16 | |
17 | 17 | $wgExtensionCredits['specialpage'][] = array( |
18 | 18 | 'name' => 'Translate', |
Index: trunk/extensions/Translate/scripts/fuzzy.php |
— | — | @@ -82,7 +82,8 @@ |
83 | 83 | $count = count($msgs); |
84 | 84 | STDOUT( "Found $count pages to update." ); |
85 | 85 | |
86 | | - foreach ( $msgs as $title => $text ) { |
| 86 | + foreach ( $msgs as $phpIsStupid ) { |
| 87 | + list( $title, $text ) = $phpIsStupid; |
87 | 88 | $this->updateMessage( $title, $text ); |
88 | 89 | } |
89 | 90 | |
— | — | @@ -114,14 +115,15 @@ |
115 | 116 | |
116 | 117 | $rows = $dbr->select( |
117 | 118 | array( 'page', 'revision', 'text' ), |
118 | | - array( 'page_title', 'old_text', 'old_flags' ), |
| 119 | + array( 'page_title', 'page_namespace', 'old_text', 'old_flags' ), |
119 | 120 | $conds, |
120 | 121 | __METHOD__ |
121 | 122 | ); |
122 | 123 | |
123 | 124 | $messagesContents = array(); |
124 | 125 | foreach ( $rows as $row ) { |
125 | | - $messagesContents[$row->page_title] = Revision::getRevisionText( $row ); |
| 126 | + $title = Title::makeTitle( $row->page_namespace, $row->page_title ); |
| 127 | + $messagesContents[] = array( $title, Revision::getRevisionText( $row ) ); |
126 | 128 | } |
127 | 129 | |
128 | 130 | $rows->free(); |
— | — | @@ -131,7 +133,7 @@ |
132 | 134 | |
133 | 135 | private function updateMessage( $title, $text ) { |
134 | 136 | global $wgTitle, $wgArticle, $wgTranslateDocumentationLanguageCode; |
135 | | - $wgTitle = Title::newFromText( "Mediawiki:$title" ); |
| 137 | + $wgTitle = $title; |
136 | 138 | |
137 | 139 | STDOUT( "Updating {$wgTitle->getPrefixedText()}... ", true ); |
138 | 140 | if ( !$wgTitle instanceof Title ) { |
Index: trunk/extensions/Translate/README |
— | — | @@ -34,6 +34,7 @@ |
35 | 35 | |
36 | 36 | == Changes in version 10 == |
37 | 37 | |
| 38 | +* 2008-07-05:1 fuzzy.php was ignoring the namespace |
38 | 39 | * 2008-07-04:2 |
39 | 40 | - use a existing hook for quick links |
40 | 41 | - possible fix for Windows |