Index: trunk/extensions/LiveTranslate/LiveTranslate.php |
— | — | @@ -25,7 +25,7 @@ |
26 | 26 | die( 'Not an entry point.' ); |
27 | 27 | } |
28 | 28 | |
29 | | -define( 'LiveTranslate_VERSION', '0.1 alpha' ); |
| 29 | +define( 'LiveTranslate_VERSION', '0.1' ); |
30 | 30 | |
31 | 31 | $wgExtensionCredits['other'][] = array( |
32 | 32 | 'path' => __FILE__, |
Index: trunk/extensions/LiveTranslate/INSTALL |
— | — | @@ -14,10 +14,33 @@ |
15 | 15 | |
16 | 16 | After this you need to run MediaWikis update script which can be found at /maintenance/update.php. |
17 | 17 | |
| 18 | +After doing this, you have installed the extension. To be able to use it in a meaningful way, you also need to take care of some configuration: |
| 19 | + |
| 20 | +== Configuration == |
| 21 | + |
| 22 | +Configuration of Live Translate is done by adding simple PHP statements to your [[Manual:LocalSettings.php|LocalSettings.php]] |
| 23 | +file. These statements need to be placed AFTER the inclusion of Live Translate. The options are listed below and their default |
| 24 | +is set in the [http://svn.wikimedia.org/viewvc/mediawiki/trunk/extensions/LiveTranslate/LiveTranslate_Settings.php?view=markup Live Translate settings file]. |
| 25 | +You should NOT modify the settings file, but can have a look at it to get an idea of how to use the settings, in case the below descriptions do not suffice. |
| 26 | + |
| 27 | +=== Google API key === |
| 28 | + |
18 | 29 | To be able to actually use Google Translate, you need to [https://code.google.com/apis/console get an API key] and |
19 | 30 | add it to your [[LocalSettings.php]] file AFTER the inclusion of the extension. |
20 | 31 | |
21 | 32 | <source lang="php"> |
22 | 33 | # Google API key |
23 | 34 | $egGoogleApiKey = 'INSERT-YOUR-KEY-HERE'; |
24 | | -</source> |
\ No newline at end of file |
| 35 | +</source> |
| 36 | + |
| 37 | +=== Available languages === |
| 38 | + |
| 39 | +You have to specify which languages users should be able to translate to. This is done by adding language codes to <code>$egLiveTranslateLanguages</code>. |
| 40 | +By default it contains only your wikis main language (as specified by <code>$wgLanguageCode</code> in [[LocalSettings.php]]). You add languages as follows: |
| 41 | + |
| 42 | +<source lang="php"> |
| 43 | +$egLiveTranslateLanguages[] = 'nl'; |
| 44 | +$egLiveTranslateLanguages[] = 'de'; |
| 45 | +</source> |
| 46 | + |
| 47 | +If there are no languages available other then the current language of the page, then the translation control will not show up. |
Index: trunk/extensions/LiveTranslate/RELEASE-NOTES |
— | — | @@ -5,7 +5,7 @@ |
6 | 6 | |
7 | 7 | |
8 | 8 | === Version 0.1 === |
9 | | -2010-12-xx |
| 9 | +2010-12-22 |
10 | 10 | |
11 | 11 | * Added simple translation interface to the right top of articles. |
12 | 12 | * Implemented translation via the Google Translate API. |