From: Rotem Liss Date: Wed, 28 Jun 2006 12:15:51 +0000 (+0000) Subject: Localisation of some English hard-coded error messages in Special:Import. X-Git-Tag: 1.31.0-rc.0~56560 X-Git-Url: https://git.cyclocoop.org/%7B%24www_url%7Dadmin/compta/exercices/journal.php?a=commitdiff_plain;h=21ef866331dcf1e13447c552c8c23b1182dfd8bc;p=lhc%2Fweb%2Fwiklou.git Localisation of some English hard-coded error messages in Special:Import. --- diff --git a/includes/SpecialImport.php b/includes/SpecialImport.php index 8a121ee013..156ea8b59b 100644 --- a/includes/SpecialImport.php +++ b/includes/SpecialImport.php @@ -56,7 +56,7 @@ function wfSpecialImport( $page = '' ) { $history ); break; default: - $source = new WikiError( "Unknown import source type" ); + $source = new WikiErrorMsg( "importunknownsource" ); } if( WikiError::isError( $source ) ) { @@ -751,7 +751,7 @@ class ImportStreamSource { function newFromFile( $filename ) { $file = @fopen( $filename, 'rt' ); if( !$file ) { - return new WikiError( "Couldn't open import file" ); + return new WikiErrorMsg( "importcantopen" ); } return new ImportStreamSource( $file ); } @@ -786,7 +786,7 @@ class ImportStreamSource { $base = Title::getInterwikiLink( $interwiki ); $link = Title::newFromText( "$interwiki:Special:Export/$page" ); if( empty( $base ) || empty( $link ) ) { - return new WikiError( 'Bad interwiki link' ); + return new WikiErrorMsg( 'importbadinterwiki' ); } else { $params = $history ? 'history=1' : ''; $url = $link->getFullUrl( $params ); diff --git a/languages/Messages.php b/languages/Messages.php index f7dc51962e..e8a729c736 100644 --- a/languages/Messages.php +++ b/languages/Messages.php @@ -1467,6 +1467,9 @@ All transwiki import actions are logged at the [[Special:Log/import|import log]] 'import-revision-count' => '$1 revision(s)', 'importnopages' => "No pages to import.", 'importfailed' => "Import failed: $1", +'importunknownsource' => "Unknown import source type", +'importcantopen' => "Couldn't open import file", +'importbadinterwiki' => "Bad interwiki link", 'importnotext' => 'Empty or no text', 'importsuccess' => 'Import succeeded!', 'importhistoryconflict' => 'Conflicting history revision exists (may have imported this page before)', diff --git a/languages/MessagesHe.php b/languages/MessagesHe.php index c66c23dadb..49a7fa128c 100644 --- a/languages/MessagesHe.php +++ b/languages/MessagesHe.php @@ -1309,6 +1309,9 @@ $NEWPAGE "import-revision-count" => "$1 גרסאות", "importnopages" => "אין דפים לייבוא.", "importfailed" => "הייבוא נכשל: $1", +"importunknownsource" => "סוג ייבוא בלתי ידוע", +"importcantopen" => "פתיחת קובץ הייבוא נכשלה", +"importbadinterwiki" => "קישור אינטרוויקי שגוי", "importnotext" => "ריק או חסר טקסט", "importsuccess" => "הייבוא הושלם בהצלחה!", "importhistoryconflict" => "ישנה התנגשות עם ההיסטוריה הקיימת של הדף (ייתכן שהדף יובא בעבר)",