Index: trunk/extensions/Translate/MessageGroups.php |
— | — | @@ -1177,17 +1177,11 @@ |
1178 | 1178 | } |
1179 | 1179 | |
1180 | 1180 | class ImportFreeImagesMessageGroup extends ExtensionMessageGroup { |
1181 | | - protected $fileExporter = null; |
1182 | 1181 | protected $label = 'Import Free Images'; |
1183 | 1182 | protected $id = 'ext-importfreeimages'; |
1184 | 1183 | |
1185 | | - protected $functionName = 'efImportFreeImagesMessages'; |
| 1184 | + protected $functionName = 'messages'; |
1186 | 1185 | protected $messageFile = 'ImportFreeImages/ImportFreeImages.i18n.php'; |
1187 | | - |
1188 | | - protected $exportStart = '\'$CODE\' => array('; |
1189 | | - protected $exportPrefix= "\t\t"; |
1190 | | - protected $exportLineP = "\t\t\t"; |
1191 | | - protected $exportEnd = '),'; |
1192 | 1186 | } |
1193 | 1187 | |
1194 | 1188 | class InputBoxMessageGroup extends ExtensionMessageGroup { |
Index: trunk/extensions/ImportFreeImages/ImportFreeImages.i18n.php |
— | — | @@ -1,190 +1,194 @@ |
2 | 2 | <?php |
3 | | -/*Internationalization of ImportFreeImages extension.*/ |
| 3 | +/** |
| 4 | + * Internationalisation file for extension ImportFreeImages. |
| 5 | + * |
| 6 | + * @addtogroup Extensions |
| 7 | +*/ |
4 | 8 | |
5 | | -function efImportFreeImagesMessages() { |
6 | | - $messages = array ( |
7 | | - /*English (ravis Derouin)*/ |
8 | | - 'en' => array ( |
9 | | - 'importfreeimages' => 'Import Free Images', |
10 | | - 'importfreeimages_description' => 'This page allows you to search properly licensed photos from flickr and import them into your wiki.', |
11 | | - 'importfreeimages_noapikey' => 'You have not configured your Flickr API Key. To do so, please obtain a API key from [http://www.flickr.com/services/api/misc.api_keys.html here] and set wgFlickrAPIKey in ImportFreeImages.php.', |
12 | | - 'importfreeimages_nophotosfound' => 'No photos were found for your search criteria \'$1\', please try again.', |
13 | | - 'importfreeimages_owner' => 'Author', |
14 | | - 'importfreeimages_importthis' => 'import this', |
15 | | - 'importfreeimages_next' => 'Next $1', |
16 | | - 'importfreeimages_filefromflickr' => '$1 by user <b>[$2]</b> from flickr. Original URL', |
17 | | - 'importfreeimages_promptuserforfilename' => 'Please enter a destination filename:', |
18 | | - 'importfreeimages_returntoform' => 'Or, click <a href=\'$1\'>here</a> to return to your search results', |
19 | | - ), |
| 9 | +$messages = array(); |
20 | 10 | |
21 | | - 'ar' => array( |
22 | | - 'importfreeimages' => 'استيراد صور حرة', |
23 | | - 'importfreeimages_description' => 'هذه الصفحة تسمح لك بالبحث في الصور المرخصة جيدا من فلكر واستيرادها إلى الويكي الخاص بك.', |
24 | | - 'importfreeimages_noapikey' => 'لم تقم بضبط مفتاح API فلكر الخاص بك. لفعل هذا، من فضلك احصل على مفتاح API من [http://www.flickr.com/services/api/misc.api_keys.html هنا] واضبط wgFlickrAPIKey في ImportFreeImages.php.', |
25 | | - 'importfreeimages_nophotosfound' => 'لا صور تم العثور عليها لمدخلة البحث الخاصة بك \'$1\'، من فضلك حاول مرة ثانية.', |
26 | | - 'importfreeimages_owner' => 'المؤلف', |
27 | | - 'importfreeimages_importthis' => 'استورد هذا', |
28 | | - 'importfreeimages_next' => '$1 التالي', |
29 | | - 'importfreeimages_filefromflickr' => '$1 بواسطة المستخدم <b>[$2]</b> من فلكر. المسار الأصلي', |
30 | | - 'importfreeimages_promptuserforfilename' => 'من فضلك أدخل اسما لتخزين الملف به:', |
31 | | - 'importfreeimages_returntoform' => 'أو، اضغط <a href=\'$1\'>هنا</a> للعودة إلى نتائج بحثك', |
32 | | - ), |
| 11 | +/* English |
| 12 | + * @author ravis Derouin |
| 13 | + */ |
| 14 | +$messages['en'] = array( |
| 15 | + 'importfreeimages' => 'Import Free Images', |
| 16 | + 'importfreeimages_description' => 'This page allows you to search properly licensed photos from flickr and import them into your wiki.', |
| 17 | + 'importfreeimages_noapikey' => 'You have not configured your Flickr API Key. To do so, please obtain a API key from [http://www.flickr.com/services/api/misc.api_keys.html here] and set wgFlickrAPIKey in ImportFreeImages.php.', |
| 18 | + 'importfreeimages_nophotosfound' => 'No photos were found for your search criteria \'$1\', please try again.', |
| 19 | + 'importfreeimages_owner' => 'Author', |
| 20 | + 'importfreeimages_importthis' => 'import this', |
| 21 | + 'importfreeimages_next' => 'Next $1', |
| 22 | + 'importfreeimages_filefromflickr' => '$1 by user <b>[$2]</b> from flickr. Original URL', |
| 23 | + 'importfreeimages_promptuserforfilename' => 'Please enter a destination filename:', |
| 24 | + 'importfreeimages_returntoform' => 'Or, click <a href=\'$1\'>here</a> to return to your search results', |
| 25 | +); |
33 | 26 | |
| 27 | +$messages['ar'] = array( |
| 28 | + 'importfreeimages' => 'استيراد صور حرة', |
| 29 | + 'importfreeimages_description' => 'هذه الصفحة تسمح لك بالبحث في الصور المرخصة جيدا من فلكر واستيرادها إلى الويكي الخاص بك.', |
| 30 | + 'importfreeimages_noapikey' => 'لم تقم بضبط مفتاح API فلكر الخاص بك. لفعل هذا، من فضلك احصل على مفتاح API من [http://www.flickr.com/services/api/misc.api_keys.html هنا] واضبط wgFlickrAPIKey في ImportFreeImages.php.', |
| 31 | + 'importfreeimages_nophotosfound' => 'لا صور تم العثور عليها لمدخلة البحث الخاصة بك \'$1\'، من فضلك حاول مرة ثانية.', |
| 32 | + 'importfreeimages_owner' => 'المؤلف', |
| 33 | + 'importfreeimages_importthis' => 'استورد هذا', |
| 34 | + 'importfreeimages_next' => '$1 التالي', |
| 35 | + 'importfreeimages_filefromflickr' => '$1 بواسطة المستخدم <b>[$2]</b> من فلكر. المسار الأصلي', |
| 36 | + 'importfreeimages_promptuserforfilename' => 'من فضلك أدخل اسما لتخزين الملف به:', |
| 37 | + 'importfreeimages_returntoform' => 'أو، اضغط <a href=\'$1\'>هنا</a> للعودة إلى نتائج بحثك', |
| 38 | +); |
| 39 | + |
34 | 40 | /** Bulgarian (Български) |
35 | 41 | * @author DCLXVI |
36 | 42 | * @author Spiritia |
37 | 43 | */ |
38 | | - 'bg' => array( |
39 | | - 'importfreeimages' => 'Внасяне на свободни картинки', |
40 | | - 'importfreeimages_description' => 'Тази страница позволява търсенето на подходящо лицензирани картинки от flickr и качването им в уикито.', |
41 | | - 'importfreeimages_noapikey' => 'Не е конфигуриран Flickr API ключ. Такъв API ключ може да се получи [http://www.flickr.com/services/api/misc.api_keys.html оттук], след което е необходимо да се настрои wgFlickrAPIKey в ImportFreeImages.php.', |
42 | | - 'importfreeimages_nophotosfound' => "Не бяха открити резултати за търсенето ви по критерия '$1'. Моля, опитайте отново.", |
43 | | - 'importfreeimages_owner' => 'Автор', |
44 | | - 'importfreeimages_next' => 'Следващи $1', |
45 | | - 'importfreeimages_promptuserforfilename' => 'Моля, въведете целево име на файла:', |
46 | | - 'importfreeimages_returntoform' => "Или щракнете <a href='$1'>тук</a> за да се върнете към резултати от търсенето си", |
47 | | - ), |
| 44 | +$messages['bg'] = array( |
| 45 | + 'importfreeimages' => 'Внасяне на свободни картинки', |
| 46 | + 'importfreeimages_description' => 'Тази страница позволява търсенето на подходящо лицензирани картинки от flickr и качването им в уикито.', |
| 47 | + 'importfreeimages_noapikey' => 'Не е конфигуриран Flickr API ключ. Такъв API ключ може да се получи [http://www.flickr.com/services/api/misc.api_keys.html оттук], след което е необходимо да се настрои wgFlickrAPIKey в ImportFreeImages.php.', |
| 48 | + 'importfreeimages_nophotosfound' => "Не бяха открити резултати за търсенето ви по критерия '$1'. Моля, опитайте отново.", |
| 49 | + 'importfreeimages_owner' => 'Автор', |
| 50 | + 'importfreeimages_next' => 'Следващи $1', |
| 51 | + 'importfreeimages_promptuserforfilename' => 'Моля, въведете целево име на файла:', |
| 52 | + 'importfreeimages_returntoform' => "Или щракнете <a href='$1'>тук</a> за да се върнете към резултати от търсенето си", |
| 53 | +); |
48 | 54 | |
49 | | - 'de' => array( |
50 | | - 'importfreeimages' => 'Import freier Bilder', |
51 | | - 'importfreeimages_description' => 'Diese Seite erlaubt dir, auf Flickr nach Bildern unter einer freien Lizenz zu suchen und diese in dein Wiki zu importieren.', |
52 | | - 'importfreeimages_noapikey' => 'Du hast noch keinen Flickr-API-Schlüssel konfiguriert. Bitte beantrage ihn [http://www.flickr.com/services/api/misc.api_keys.html hier] und setze ihn in $wgFlickrAPIKey in ImportFreeImages.php ein.', |
53 | | - 'importfreeimages_nophotosfound' => 'Es wurden keine Fotos mit den Suchkriterien „$1“ gefunden.', |
54 | | - 'importfreeimages_owner' => 'Autor', |
55 | | - 'importfreeimages_importthis' => 'importieren', |
56 | | - 'importfreeimages_next' => 'Nächste $1', |
57 | | - 'importfreeimages_filefromflickr' => '$1 von Benutzer <b>[$2]</b> von flickr. Original URL', |
58 | | - 'importfreeimages_promptuserforfilename' => 'Bitte gebe einen Ziel-Dateinamen ein:', |
59 | | - 'importfreeimages_returntoform' => 'Oder klicke <a href=\'$1\'>hier</a>, um zu der Seite mit den Suchergebnissen zurückzukommen.', |
60 | | - ), |
| 55 | +$messages['de'] = array( |
| 56 | + 'importfreeimages' => 'Import freier Bilder', |
| 57 | + 'importfreeimages_description' => 'Diese Seite erlaubt dir, auf Flickr nach Bildern unter einer freien Lizenz zu suchen und diese in dein Wiki zu importieren.', |
| 58 | + 'importfreeimages_noapikey' => 'Du hast noch keinen Flickr-API-Schlüssel konfiguriert. Bitte beantrage ihn [http://www.flickr.com/services/api/misc.api_keys.html hier] und setze ihn in $wgFlickrAPIKey in ImportFreeImages.php ein.', |
| 59 | + 'importfreeimages_nophotosfound' => 'Es wurden keine Fotos mit den Suchkriterien „$1“ gefunden.', |
| 60 | + 'importfreeimages_owner' => 'Autor', |
| 61 | + 'importfreeimages_importthis' => 'importieren', |
| 62 | + 'importfreeimages_next' => 'Nächste $1', |
| 63 | + 'importfreeimages_filefromflickr' => '$1 von Benutzer <b>[$2]</b> von flickr. Original URL', |
| 64 | + 'importfreeimages_promptuserforfilename' => 'Bitte gebe einen Ziel-Dateinamen ein:', |
| 65 | + 'importfreeimages_returntoform' => 'Oder klicke <a href=\'$1\'>hier</a>, um zu der Seite mit den Suchergebnissen zurückzukommen.', |
| 66 | +); |
61 | 67 | |
62 | 68 | /*French (Bertrand GRONDIN)*/ |
63 | | - 'fr' => array( |
64 | | - 'importfreeimages' => 'Importer des Images Libres', |
65 | | - 'importfreeimages_description' => 'Cette page vous permet de rechercher proprement des images sous licences depuis flickr et de les importer dans votre wiki.', |
66 | | - 'importfreeimages_noapikey' => 'Vous n’avez pas configuré votre Clef API Flickr. Pour ce faire, vous êtes prié d’obtenir une clef API à partir de [http://www.flickr.com/services/api/misc.api_keys.html ce lien] et de configurer wgFlickrAPIKey dans ImportFreeImages.php.', |
67 | | - 'importfreeimages_nophotosfound' => 'Aucune photo n’a été trouvée à partir de vos critères de recherches \'$1\', veuillez essayer à nouveau.', |
68 | | - 'importfreeimages_owner' => 'Auteur', |
69 | | - 'importfreeimages_importthis' => 'l’importer', |
70 | | - 'importfreeimages_next' => ' $1 suivants', |
71 | | - 'importfreeimages_filefromflickr' => '$1 par l’utilisateur <b>[$2]</b> depuis flickr. URL d’origine ', |
72 | | - 'importfreeimages_promptuserforfilename' => 'Veuillez indiquer le nom du fichier de destination : ', |
73 | | - 'importfreeimages_returntoform' => 'ou, cliquez <a href=\'$1\'>ici</a> pour revenir à votre liste de résultats.', |
74 | | - ), |
| 69 | +$messages['fr'] = array( |
| 70 | + 'importfreeimages' => 'Importer des Images Libres', |
| 71 | + 'importfreeimages_description' => 'Cette page vous permet de rechercher proprement des images sous licences depuis flickr et de les importer dans votre wiki.', |
| 72 | + 'importfreeimages_noapikey' => 'Vous n’avez pas configuré votre Clef API Flickr. Pour ce faire, vous êtes prié d’obtenir une clef API à partir de [http://www.flickr.com/services/api/misc.api_keys.html ce lien] et de configurer wgFlickrAPIKey dans ImportFreeImages.php.', |
| 73 | + 'importfreeimages_nophotosfound' => 'Aucune photo n’a été trouvée à partir de vos critères de recherches \'$1\', veuillez essayer à nouveau.', |
| 74 | + 'importfreeimages_owner' => 'Auteur', |
| 75 | + 'importfreeimages_importthis' => 'l’importer', |
| 76 | + 'importfreeimages_next' => ' $1 suivants', |
| 77 | + 'importfreeimages_filefromflickr' => '$1 par l’utilisateur <b>[$2]</b> depuis flickr. URL d’origine ', |
| 78 | + 'importfreeimages_promptuserforfilename' => 'Veuillez indiquer le nom du fichier de destination : ', |
| 79 | + 'importfreeimages_returntoform' => 'ou, cliquez <a href=\'$1\'>ici</a> pour revenir à votre liste de résultats.', |
| 80 | +); |
75 | 81 | |
76 | | - 'gl' => array( |
77 | | - 'importfreeimages' => 'Importar Imaxes Libres', |
78 | | - 'importfreeimages_description' => 'Esta páxina permítelle procurar fotos de flickr con licenza correcta e importalos ao seu wiki.', |
79 | | - 'importfreeimages_nophotosfound' => 'Ningunhas fotos foron atopadas cos criterios \'$1\' de procura, ténteo de novo.', |
80 | | - 'importfreeimages_owner' => 'Autor', |
81 | | - 'importfreeimages_importthis' => 'importar isto', |
82 | | - 'importfreeimages_next' => 'Seguinte $1', |
83 | | - 'importfreeimages_filefromflickr' => '$1 polo usuario <b>[$2]</b> de flickr. Orixinal URL', |
84 | | - 'importfreeimages_promptuserforfilename' => 'Introduza un nome de ficheiro de destino:', |
85 | | - 'importfreeimages_returntoform' => 'Ou, prema <a href=\'$1\'>here</a> para voltar á súa procura de resultados', |
86 | | - ), |
| 82 | +$messages['gl'] = array( |
| 83 | + 'importfreeimages' => 'Importar Imaxes Libres', |
| 84 | + 'importfreeimages_description' => 'Esta páxina permítelle procurar fotos de flickr con licenza correcta e importalos ao seu wiki.', |
| 85 | + 'importfreeimages_nophotosfound' => 'Ningunhas fotos foron atopadas cos criterios \'$1\' de procura, ténteo de novo.', |
| 86 | + 'importfreeimages_owner' => 'Autor', |
| 87 | + 'importfreeimages_importthis' => 'importar isto', |
| 88 | + 'importfreeimages_next' => 'Seguinte $1', |
| 89 | + 'importfreeimages_filefromflickr' => '$1 polo usuario <b>[$2]</b> de flickr. Orixinal URL', |
| 90 | + 'importfreeimages_promptuserforfilename' => 'Introduza un nome de ficheiro de destino:', |
| 91 | + 'importfreeimages_returntoform' => 'Ou, prema <a href=\'$1\'>here</a> para voltar á súa procura de resultados', |
| 92 | +); |
87 | 93 | |
88 | | - 'hsb' => array( |
89 | | - 'importfreeimages' => 'Swobodne wobrazy importować', |
90 | | - 'importfreeimages_description' => 'Tuta strona ći dowola na Flickr za wobrazami z prihódnej ličencu pytać a je do swojeho wiki importować.', |
91 | | - 'importfreeimages_noapikey' => 'Njejsy swój kluč Flickr API konfigurował. Prošu požadaj jón [http://www.flickr.com/services/api/misc.api_keys.html jowle] a nastaj $wgFlickrAPIKey w ImportFreeImages.php.', |
92 | | - 'importfreeimages_nophotosfound' => 'Njejsu so žane fota za twoje pytanske kriterije "$1" namakali.', |
93 | | - 'importfreeimages_owner' => 'Awtor', |
94 | | - 'importfreeimages_importthis' => 'importować', |
95 | | - 'importfreeimages_next' => 'Přichodny $1', |
96 | | - 'importfreeimages_filefromflickr' => '$1 wot wužiwarja <b>[$2]</b> z flickra. Originalny URL', |
97 | | - 'importfreeimages_promptuserforfilename' => 'Prošu zapodaj mjeno ciloweje dataje:', |
98 | | - 'importfreeimages_returntoform' => 'Abo klikń <a href=\'$1\'>sem</a>, zo by k stronje z pytanskimi wuslědkami wróćił.', |
99 | | - ), |
| 94 | +$messages['hsb'] = array( |
| 95 | + 'importfreeimages' => 'Swobodne wobrazy importować', |
| 96 | + 'importfreeimages_description' => 'Tuta strona ći dowola na Flickr za wobrazami z prihódnej ličencu pytać a je do swojeho wiki importować.', |
| 97 | + 'importfreeimages_noapikey' => 'Njejsy swój kluč Flickr API konfigurował. Prošu požadaj jón [http://www.flickr.com/services/api/misc.api_keys.html jowle] a nastaj $wgFlickrAPIKey w ImportFreeImages.php.', |
| 98 | + 'importfreeimages_nophotosfound' => 'Njejsu so žane fota za twoje pytanske kriterije "$1" namakali.', |
| 99 | + 'importfreeimages_owner' => 'Awtor', |
| 100 | + 'importfreeimages_importthis' => 'importować', |
| 101 | + 'importfreeimages_next' => 'Přichodny $1', |
| 102 | + 'importfreeimages_filefromflickr' => '$1 wot wužiwarja <b>[$2]</b> z flickra. Originalny URL', |
| 103 | + 'importfreeimages_promptuserforfilename' => 'Prošu zapodaj mjeno ciloweje dataje:', |
| 104 | + 'importfreeimages_returntoform' => 'Abo klikń <a href=\'$1\'>sem</a>, zo by k stronje z pytanskimi wuslědkami wróćił.', |
| 105 | +); |
100 | 106 | |
101 | 107 | /** Luxembourgish (Lëtzebuergesch) |
102 | 108 | * @author Robby |
103 | 109 | */ |
104 | | - 'lb' => array( |
105 | | - 'importfreeimages_owner' => 'Auteur:', |
106 | | - ), |
| 110 | +$messages['lb'] = array( |
| 111 | + 'importfreeimages_owner' => 'Auteur:', |
| 112 | +); |
107 | 113 | |
108 | | - 'nl' => array( |
109 | | - 'importfreeimages' => 'Vrije afbeeldingen importeren', |
110 | | - 'importfreeimages_description' => 'Deze pagina laat u toe om juist gelicenseerde foto\'s van flickr te zoeken and die te importeren naar uw wiki.', |
111 | | - 'importfreeimages_noapikey' => 'U heeft geen Flickr API Key ingesteld. U kunt een API-sleutel [http://www.flickr.com/services/api/misc.api_keys.html hier] verkrijgen en instellen als wgFlickrAPIKey in ImportFreeImages.php.', |
112 | | - 'importfreeimages_nophotosfound' => 'Er zijn geen foto\'s gevonden voor uw zoekcriteria \'$1\', probeer opniew.', |
113 | | - 'importfreeimages_owner' => 'Auteur', |
114 | | - 'importfreeimages_importthis' => 'dit importeren', |
115 | | - 'importfreeimages_next' => 'Volgende $1', |
116 | | - 'importfreeimages_filefromflickr' => '$1 door gebruiker <b>[$2]</b> van flickr. Oorspronkelijke URL', |
117 | | - 'importfreeimages_promptuserforfilename' => 'Gelieve een bestandsnaam op te geven:', |
118 | | - 'importfreeimages_returntoform' => 'Of, klik <a href=\'$1\'>hier</a> om terug te keren naar uw zoekresultaten', |
119 | | - ), |
120 | | - 'no' => array( |
121 | | - 'importfreeimages' => 'Imperter frie bilder', |
122 | | - 'importfreeimages_description' => 'Denne siden lar deg søke i bilder med riktig lisens på Flickr og importere dem til wikien din.', |
123 | | - 'importfreeimages_noapikey' => 'Du har ikke konfigurert API-nøkkelen din for Flickr. For å gjøre det må du skaffe en API-nøkkel [http://www.flickr.com/services/api/misc.api_keys.html herfra] og sette wgFlickrAPIKey i ImportFreeImages.php.', |
124 | | - 'importfreeimages_nophotosfound' => 'Ingen bilder ble funnet for søket «$1». Prøv igjen.', |
125 | | - 'importfreeimages_owner' => 'Opphavsperson', |
126 | | - 'importfreeimages_importthis' => 'importer', |
127 | | - 'importfreeimages_next' => 'Neste $1', |
128 | | - 'importfreeimages_filefromflickr' => '$1 av brukeren <b>[$2]</b> fra Flickr. Original URL', |
129 | | - 'importfreeimages_promptuserforfilename' => 'Skriv inn et målnavn for filen:', |
130 | | - 'importfreeimages_returntoform' => 'Elle rklikk <a href="$1">her</a> for å gå tilbake til søkeresultatene', |
131 | | - ), |
| 114 | +$messages['nl'] = array( |
| 115 | + 'importfreeimages' => 'Vrije afbeeldingen importeren', |
| 116 | + 'importfreeimages_description' => 'Deze pagina laat u toe om juist gelicenseerde foto\'s van flickr te zoeken and die te importeren naar uw wiki.', |
| 117 | + 'importfreeimages_noapikey' => 'U heeft geen Flickr API Key ingesteld. U kunt een API-sleutel [http://www.flickr.com/services/api/misc.api_keys.html hier] verkrijgen en instellen als wgFlickrAPIKey in ImportFreeImages.php.', |
| 118 | + 'importfreeimages_nophotosfound' => 'Er zijn geen foto\'s gevonden voor uw zoekcriteria \'$1\', probeer opniew.', |
| 119 | + 'importfreeimages_owner' => 'Auteur', |
| 120 | + 'importfreeimages_importthis' => 'dit importeren', |
| 121 | + 'importfreeimages_next' => 'Volgende $1', |
| 122 | + 'importfreeimages_filefromflickr' => '$1 door gebruiker <b>[$2]</b> van flickr. Oorspronkelijke URL', |
| 123 | + 'importfreeimages_promptuserforfilename' => 'Gelieve een bestandsnaam op te geven:', |
| 124 | + 'importfreeimages_returntoform' => 'Of, klik <a href=\'$1\'>hier</a> om terug te keren naar uw zoekresultaten', |
| 125 | +); |
132 | 126 | |
| 127 | +$messages['no'] = array( |
| 128 | + 'importfreeimages' => 'Imperter frie bilder', |
| 129 | + 'importfreeimages_description' => 'Denne siden lar deg søke i bilder med riktig lisens på Flickr og importere dem til wikien din.', |
| 130 | + 'importfreeimages_noapikey' => 'Du har ikke konfigurert API-nøkkelen din for Flickr. For å gjøre det må du skaffe en API-nøkkel [http://www.flickr.com/services/api/misc.api_keys.html herfra] og sette wgFlickrAPIKey i ImportFreeImages.php.', |
| 131 | + 'importfreeimages_nophotosfound' => 'Ingen bilder ble funnet for søket «$1». Prøv igjen.', |
| 132 | + 'importfreeimages_owner' => 'Opphavsperson', |
| 133 | + 'importfreeimages_importthis' => 'importer', |
| 134 | + 'importfreeimages_next' => 'Neste $1', |
| 135 | + 'importfreeimages_filefromflickr' => '$1 av brukeren <b>[$2]</b> fra Flickr. Original URL', |
| 136 | + 'importfreeimages_promptuserforfilename' => 'Skriv inn et målnavn for filen:', |
| 137 | + 'importfreeimages_returntoform' => 'Elle rklikk <a href="$1">her</a> for å gå tilbake til søkeresultatene', |
| 138 | +); |
| 139 | + |
133 | 140 | /** Occitan (Occitan) |
134 | 141 | * @author Cedric31 |
135 | 142 | */ |
136 | | - 'oc' => array( |
137 | | - 'importfreeimages' => "Importar d'Imatges Liures", |
138 | | - 'importfreeimages_description' => "Aquesta pagina vos permet de recercar propriament d'imatges jos licéncias dempuèi flickr e de los importar dins vòstre wiki.", |
139 | | - 'importfreeimages_noapikey' => "Avètz pas configurat vòstra Clau API Flickr. Per o far, obtengatz una clau API a partir d' [http://www.flickr.com/services/api/misc.api_keys.html aqueste ligam] e configuratz wgFlickrAPIKey dins ImportFreeImages.php.", |
140 | | - 'importfreeimages_nophotosfound' => "Cap de fòto es pas estada trobada a partir de vòstres critèris de recèrcas '$1', ensajatz tornamai.", |
141 | | - 'importfreeimages_owner' => 'Autor', |
142 | | - 'importfreeimages_importthis' => 'l’importar', |
143 | | - 'importfreeimages_next' => '$1 seguents', |
144 | | - 'importfreeimages_filefromflickr' => '$1 per l’utilizaire <b>[$2]</b> dempuèi flickr. URL d’origina', |
145 | | - 'importfreeimages_promptuserforfilename' => 'Indicatz lo nom del fichièr de destinacion', |
146 | | - 'importfreeimages_returntoform' => "o, clicatz <a href='$1'>aicí</a> per tornar a vòstra lista de resultats.", |
147 | | - ), |
| 143 | +$messages['oc'] = array( |
| 144 | + 'importfreeimages' => "Importar d'Imatges Liures", |
| 145 | + 'importfreeimages_description' => "Aquesta pagina vos permet de recercar propriament d'imatges jos licéncias dempuèi flickr e de los importar dins vòstre wiki.", |
| 146 | + 'importfreeimages_noapikey' => "Avètz pas configurat vòstra Clau API Flickr. Per o far, obtengatz una clau API a partir d' [http://www.flickr.com/services/api/misc.api_keys.html aqueste ligam] e configuratz wgFlickrAPIKey dins ImportFreeImages.php.", |
| 147 | + 'importfreeimages_nophotosfound' => "Cap de fòto es pas estada trobada a partir de vòstres critèris de recèrcas '$1', ensajatz tornamai.", |
| 148 | + 'importfreeimages_owner' => 'Autor', |
| 149 | + 'importfreeimages_importthis' => 'l’importar', |
| 150 | + 'importfreeimages_next' => '$1 seguents', |
| 151 | + 'importfreeimages_filefromflickr' => '$1 per l’utilizaire <b>[$2]</b> dempuèi flickr. URL d’origina', |
| 152 | + 'importfreeimages_promptuserforfilename' => 'Indicatz lo nom del fichièr de destinacion', |
| 153 | + 'importfreeimages_returntoform' => "o, clicatz <a href='$1'>aicí</a> per tornar a vòstra lista de resultats.", |
| 154 | +); |
148 | 155 | |
149 | 156 | /** Slovak (Slovenčina) |
150 | 157 | * @author Helix84 |
151 | 158 | */ |
152 | | - 'sk' => array( |
153 | | - 'importfreeimages' => 'Importovať slobodné obrázky', |
154 | | - 'importfreeimages_description' => 'Táto stránka vám umožní importovať správne licencované obrázky z flickr a importovať ich na vašu wiki.', |
155 | | - 'importfreeimages_noapikey' => 'Nenakonfigurovali ste kľúč API Flickr. Urobíte tak po získaní kľúča API [http://www.flickr.com/services/api/misc.api_keys.html odtiaľto] a nastavení premennej wgFlickrAPIKey v ImportFreeImages.php.', |
156 | | - 'importfreeimages_nophotosfound' => 'Neboli nájdené žiadne obrázky zodpovedajúce vašim kritériám vyhľadávania „$1“. Prosím, skúste to znova.', |
157 | | - 'importfreeimages_owner' => 'Autor', |
158 | | - 'importfreeimages_importthis' => 'importovať toto', |
159 | | - 'importfreeimages_next' => 'Ďalších $1', |
160 | | - 'importfreeimages_filefromflickr' => '$1 od používateľa <b>[$2]</b> z flickr. Pôvodný URL', |
161 | | - 'importfreeimages_promptuserforfilename' => 'prosím, zadajte cieľový názov súboru:', |
162 | | - 'importfreeimages_returntoform' => "Alebo sa vráťte na <a href='$1'>výsledky vášho vyhľadávania</a>", |
163 | | - ), |
| 159 | +$messages['sk'] = array( |
| 160 | + 'importfreeimages' => 'Importovať slobodné obrázky', |
| 161 | + 'importfreeimages_description' => 'Táto stránka vám umožní importovať správne licencované obrázky z flickr a importovať ich na vašu wiki.', |
| 162 | + 'importfreeimages_noapikey' => 'Nenakonfigurovali ste kľúč API Flickr. Urobíte tak po získaní kľúča API [http://www.flickr.com/services/api/misc.api_keys.html odtiaľto] a nastavení premennej wgFlickrAPIKey v ImportFreeImages.php.', |
| 163 | + 'importfreeimages_nophotosfound' => 'Neboli nájdené žiadne obrázky zodpovedajúce vašim kritériám vyhľadávania „$1“. Prosím, skúste to znova.', |
| 164 | + 'importfreeimages_owner' => 'Autor', |
| 165 | + 'importfreeimages_importthis' => 'importovať toto', |
| 166 | + 'importfreeimages_next' => 'Ďalších $1', |
| 167 | + 'importfreeimages_filefromflickr' => '$1 od používateľa <b>[$2]</b> z flickr. Pôvodný URL', |
| 168 | + 'importfreeimages_promptuserforfilename' => 'prosím, zadajte cieľový názov súboru:', |
| 169 | + 'importfreeimages_returntoform' => "Alebo sa vráťte na <a href='$1'>výsledky vášho vyhľadávania</a>", |
| 170 | +); |
164 | 171 | |
165 | 172 | /** Seeltersk (Seeltersk) |
166 | 173 | * @author Pyt |
167 | 174 | */ |
168 | | - 'stq' => array( |
169 | | - 'importfreeimages' => 'Import fon fräie Bielden', |
170 | | - 'importfreeimages_description' => 'Disse Siede ferlööwet die, ap Flickr ätter Bielden unner ne fräie Lizenz tou säiken un do in dien Wiki tou importierjen.', |
171 | | - 'importfreeimages_noapikey' => 'Du hääst noch naan Flickr-API-Koai konfigurierd. Jädden beandraach him [http://www.flickr.com/services/api/misc.api_keys.html hier] un sät him in $wgFlickrAPIKey in ImportFreeImages.php ien.', |
172 | | - 'importfreeimages_nophotosfound' => 'Der wuuden neen Fotos mäd do Säikkriterien „$1“ fuunen.', |
173 | | - 'importfreeimages_owner' => 'Autor', |
174 | | - 'importfreeimages_importthis' => 'importierje', |
175 | | - 'importfreeimages_next' => 'Naiste $1', |
176 | | - 'importfreeimages_filefromflickr' => '$1 fon Benutser <b>[$2]</b> fon flickr. Originoal URL', |
177 | | - 'importfreeimages_promptuserforfilename' => 'Reek n Siel-Doatäinoome ien:', |
178 | | - 'importfreeimages_returntoform' => "Of klik <a href='$1'>hier</a>, uum tou ju Siede mäd do Säikresultoate touräächtoukuumen.", |
179 | | - ), |
| 175 | +$messages['stq'] = array( |
| 176 | + 'importfreeimages' => 'Import fon fräie Bielden', |
| 177 | + 'importfreeimages_description' => 'Disse Siede ferlööwet die, ap Flickr ätter Bielden unner ne fräie Lizenz tou säiken un do in dien Wiki tou importierjen.', |
| 178 | + 'importfreeimages_noapikey' => 'Du hääst noch naan Flickr-API-Koai konfigurierd. Jädden beandraach him [http://www.flickr.com/services/api/misc.api_keys.html hier] un sät him in $wgFlickrAPIKey in ImportFreeImages.php ien.', |
| 179 | + 'importfreeimages_nophotosfound' => 'Der wuuden neen Fotos mäd do Säikkriterien „$1“ fuunen.', |
| 180 | + 'importfreeimages_owner' => 'Autor', |
| 181 | + 'importfreeimages_importthis' => 'importierje', |
| 182 | + 'importfreeimages_next' => 'Naiste $1', |
| 183 | + 'importfreeimages_filefromflickr' => '$1 fon Benutser <b>[$2]</b> fon flickr. Originoal URL', |
| 184 | + 'importfreeimages_promptuserforfilename' => 'Reek n Siel-Doatäinoome ien:', |
| 185 | + 'importfreeimages_returntoform' => "Of klik <a href='$1'>hier</a>, uum tou ju Siede mäd do Säikresultoate touräächtoukuumen.", |
| 186 | +); |
180 | 187 | |
181 | 188 | /** Volapük (Volapük) |
182 | 189 | * @author Malafaya |
183 | 190 | */ |
184 | | - 'vo' => array( |
185 | | - 'importfreeimages_owner' => 'Lautan', |
186 | | - 'importfreeimages_next' => 'Sököl $1', |
187 | | - 'importfreeimages_filefromflickr' => "$1 fa geban: <b>[$2]</b> de 'flickr'. 'URL' rigik", |
188 | | - ), |
189 | | - ); |
190 | | - return $messages; |
191 | | -} |
| 191 | +$messages['vo'] = array( |
| 192 | + 'importfreeimages_owner' => 'Lautan', |
| 193 | + 'importfreeimages_next' => 'Sököl $1', |
| 194 | + 'importfreeimages_filefromflickr' => "$1 fa geban: <b>[$2]</b> de 'flickr'. 'URL' rigik", |
| 195 | +); |
Index: trunk/extensions/ImportFreeImages/ImportFreeImages.php |
— | — | @@ -4,7 +4,7 @@ |
5 | 5 | |
6 | 6 | /**#@+ |
7 | 7 | * Provides a way of importing properly licensed photos from flickr |
8 | | - * |
| 8 | + * |
9 | 9 | * @addtogroup Extensions |
10 | 10 | * |
11 | 11 | * @link http://www.mediawiki.org/wiki/Extension:ImportFreeImages Documentation |
— | — | @@ -35,22 +35,21 @@ |
36 | 36 | |
37 | 37 | $wgExtensionCredits['other'][] = array( |
38 | 38 | 'name' => 'ImportFreeImages', |
| 39 | + 'version' => '2008-01-11', |
39 | 40 | 'author' => 'Travis Derouin', |
40 | 41 | 'description' => 'Provides a way of importing properly licensed photos from flickr.', |
41 | 42 | 'url' => 'http://www.mediawiki.org/wiki/Extension:ImportFreeImages', |
42 | 43 | ); |
43 | 44 | |
| 45 | +$wgExtensionMessagesFiles['ImportFreeImages'] = dirname(__FILE__) . '/ImportFreeImages.i18n.php'; |
| 46 | + |
44 | 47 | function wfImportFreeImages() { |
45 | 48 | |
46 | 49 | SpecialPage::AddPage( new SpecialPage( 'ImportFreeImages' ) ); |
47 | | - require_once( dirname( __FILE__ ) . '/ImportFreeImages.i18n.php' ); |
48 | | - global $wgMessageCache; |
49 | | - foreach( efImportFreeImagesMessages() as $lang => $messages ) { |
50 | | - $wgMessageCache->addMessages( $messages, $lang ); |
51 | | - } |
| 50 | + wfLoadExtensionMessages( 'ImportFreeImages' ); |
52 | 51 | } |
53 | 52 | |
54 | | -// I wish I didn't have to copy paste most of |
| 53 | +// I wish I didn't have to copy paste most of |
55 | 54 | |
56 | 55 | function wfIIF_uploadWarning($u) { |
57 | 56 | global $wgOut; |
— | — | @@ -110,21 +109,21 @@ |
111 | 110 | global $wgIFI_ResultsPerPage, $wgIFI_FlickrSort, $wgIFI_FlickrLicense, $wgIFI_ResultsPerRow, $wgIFI_CreditsTemplate; |
112 | 111 | global $wgIFI_GetOriginal, $wgIFI_PromptForFilename, $wgIFI_AppendRandomNumber, $wgIFI_FlickrSearchBy, $wgIFI_ThumbType; |
113 | 112 | require_once("phpFlickr-2.0.0/phpFlickr.php"); |
114 | | - |
| 113 | + |
115 | 114 | $fname = "wfSpecialImportFreeImages"; |
116 | 115 | $importPage = Title::makeTitle(NS_SPECIAL, "ImportFreeImages"); |
117 | 116 | |
118 | 117 | if( $wgUser->isAnon() ) { |
119 | 118 | $wgOut->errorpage( 'uploadnologin', 'uploadnologintext' ); |
120 | 119 | return; |
121 | | - } |
| 120 | + } |
122 | 121 | |
123 | 122 | if (empty($wgIFI_FlickrAPIKey)) { |
124 | 123 | // error - need to set $wgIFI_FlickrAPIKey to use this extension |
125 | 124 | $wgOut->errorpage('error', 'importfreeimages_noapikey'); |
126 | 125 | return; |
127 | | - } |
128 | | - $q = ''; |
| 126 | + } |
| 127 | + $q = ''; |
129 | 128 | if (isset($_GET['q']) && !$wgRequest->wasPosted() ) { |
130 | 129 | $q = $_GET['q']; |
131 | 130 | } |
— | — | @@ -134,15 +133,15 @@ |
135 | 134 | if ($wgRequest->wasPosted() && isset($_POST['url'])) { |
136 | 135 | $import = $_POST['url']; |
137 | 136 | if (!preg_match('/^http:\/\/farm[0-9]+.static.flickr.com/', $import)) { |
138 | | - $wgOut->errorpage('error', 'importfreeimages_invalidurl'); |
| 137 | + $wgOut->errorpage('error', 'importfreeimages_invalidurl'); |
139 | 138 | return; |
140 | 139 | } |
141 | | - |
| 140 | + |
142 | 141 | $f = new phpFlickr($wgIFI_FlickrAPIKey); |
143 | | - |
| 142 | + |
144 | 143 | if ($wgIFI_GetOriginal) { |
145 | 144 | // get URL of original :1 |
146 | | - |
| 145 | + |
147 | 146 | $sizes = $f->photos_getSizes($_POST['id']); |
148 | 147 | $original = ''; |
149 | 148 | foreach ($sizes as $size) { |
— | — | @@ -154,19 +153,19 @@ |
155 | 154 | } |
156 | 155 | } |
157 | 156 | //somtimes Large is returned but no Original! |
158 | | - if ($original == '' && $large != '') |
159 | | - $import = $large; |
| 157 | + if ($original == '' && $large != '') |
| 158 | + $import = $large; |
160 | 159 | } |
161 | 160 | |
162 | 161 | // store the contents of the file |
163 | | - $pageContents = file_get_contents($import); |
| 162 | + $pageContents = file_get_contents($import); |
164 | 163 | $name =$wgTmpDirectory . "/flickr-" . rand(0,999999); |
165 | 164 | $r = fopen($name, "w"); |
166 | | - $size = fwrite ( $r, $pageContents); |
| 165 | + $size = fwrite ( $r, $pageContents); |
167 | 166 | fclose($r); |
168 | 167 | chmod( $name, 0777 ); |
169 | 168 | $info = $f->photos_getInfo($_POST['id']); |
170 | | - |
| 169 | + |
171 | 170 | if (!empty($wgIFI_CreditsTemplate)) { |
172 | 171 | $caption = "{{" . $wgIFI_CreditsTemplate . $info['license'] . "|{$_POST['id']}|" . urldecode($_POST['owner']) . "|" . urldecode($_POST['name']). "}}"; |
173 | 172 | } else { |
— | — | @@ -193,7 +192,7 @@ |
194 | 193 | $import = $fname; |
195 | 194 | |
196 | 195 | /* |
197 | | - $arr = array ( "size" => $size, "tempname" => $name, |
| 196 | + $arr = array ( "size" => $size, "tempname" => $name, |
198 | 197 | "caption" => $caption, |
199 | 198 | "url" => $import, "title" => $_POST['t'] ); |
200 | 199 | */ |
— | — | @@ -202,11 +201,11 @@ |
203 | 202 | $filename = str_replace(":", "", $filename); |
204 | 203 | $filename = preg_replace('/ [ ]*/', ' ', $filename); |
205 | 204 | |
206 | | - if (!class_exists("UploadForm")) |
| 205 | + if (!class_exists("UploadForm")) |
207 | 206 | require_once('includes/SpecialUpload.php'); |
208 | 207 | $u = new UploadForm($wgRequest); |
209 | 208 | $u->mUploadTempName = $name; |
210 | | - $u->mUploadSize = $size; |
| 209 | + $u->mUploadSize = $size; |
211 | 210 | $u->mUploadDescription = $caption; |
212 | 211 | $u->mRemoveTempFile = true; |
213 | 212 | $u->mIgnoreWarning = true; |
— | — | @@ -224,7 +223,7 @@ |
225 | 224 | $sk = $wgUser->getSkin(); |
226 | 225 | $dlink = $sk->makeKnownLinkObj( $t ); |
227 | 226 | $warning .= '<li>'.wfMsgHtml( 'fileexists', $dlink ).'</li>'; |
228 | | - |
| 227 | + |
229 | 228 | // use our own upload warning as we dont have a 'reupload' feature |
230 | 229 | wfIIF_uploadWarning ($u); |
231 | 230 | return; |
— | — | @@ -238,16 +237,16 @@ |
239 | 238 | <form method=GET action='" . $importPage->getFullURL() . "'>".wfMsg('search'). |
240 | 239 | ": <input type=text name=q value='" . htmlspecialchars($q) . "'><input type=submit value=".wfMsg('search')."></form>"); |
241 | 240 | |
242 | | - if ($q != '') { |
| 241 | + if ($q != '') { |
243 | 242 | $page = $_GET['p']; |
244 | 243 | if ($page == '') $page = 1; |
245 | 244 | $f = new phpFlickr($wgIFI_FlickrAPIKey); |
246 | 245 | $q = $_GET['q']; |
247 | 246 | // TODO: get the right licenses |
248 | 247 | $photos = $f->photos_search(array( |
249 | | - "$wgIFI_FlickrSearchBy"=>"$q", "tag_mode"=>"any", |
250 | | - "page" => $page, |
251 | | - "per_page" => $wgIFI_ResultsPerPage, "license" => $wgIFI_FlickrLicense, |
| 248 | + "$wgIFI_FlickrSearchBy"=>"$q", "tag_mode"=>"any", |
| 249 | + "page" => $page, |
| 250 | + "per_page" => $wgIFI_ResultsPerPage, "license" => $wgIFI_FlickrLicense, |
252 | 251 | "sort" => $wgIFI_FlickrSort )); |
253 | 252 | |
254 | 253 | $i = 0; |
— | — | @@ -286,7 +285,7 @@ |
287 | 286 | } |
288 | 287 | |
289 | 288 | </script> |
290 | | - |
| 289 | + |
291 | 290 | "); |
292 | 291 | foreach ($photos['photo'] as $photo) { |
293 | 292 | if ($i % $wgIFI_ResultsPerRow == 0) $wgOut->addHTML("<tr>"); |
— | — | @@ -299,10 +298,10 @@ |
300 | 299 | $wgOut->addHTML( "</a><br/>" ); |
301 | 300 | //$wgOut->addHTML( "<img src=http://static.flickr.com/" . $photo['server'] . "/" . $photo['id'] . "_" . $photo['secret'] . "." . "jpg>" ); |
302 | 301 | $url="http://farm{$photo['farm']}.static.flickr.com/{$photo['server']}/{$photo['id']}_{$photo['secret']}.jpg"; |
303 | | - $wgOut->addHTML( "<img src=\"http://farm{$photo['farm']}.static.flickr.com/{$photo['server']}/{$photo['id']}_{$photo['secret']}_{$wgIFI_ThumbType}.jpg\">" ); |
| 302 | + $wgOut->addHTML( "<img src=\"http://farm{$photo['farm']}.static.flickr.com/{$photo['server']}/{$photo['id']}_{$photo['secret']}_{$wgIFI_ThumbType}.jpg\">" ); |
304 | 303 | |
305 | | - $wgOut->addHTML( "<br/>(<a href='#' onclick=\"s2('$url', '{$photo['id']}','{$photo['owner']}', '" |
306 | | - . urlencode($owner['username'] ) . "', '" . urlencode($photo['title']) . "');\">" . |
| 304 | + $wgOut->addHTML( "<br/>(<a href='#' onclick=\"s2('$url', '{$photo['id']}','{$photo['owner']}', '" |
| 305 | + . urlencode($owner['username'] ) . "', '" . urlencode($photo['title']) . "');\">" . |
307 | 306 | wfMsg('importfreeimages_importthis') . "</a>)\n" ); |
308 | 307 | $wgOut->addHTML("</td>"); |
309 | 308 | if ($i % $wgIFI_ResultsPerRow == ($wgIFI_ResultsPerRow - 1) ) $wgOut->addHTML("</tr>"); |