You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@nutch.apache.org by Apache Wiki <wi...@apache.org> on 2009/06/20 16:35:53 UTC

[Nutch Wiki] Update of "AddingNewLocalization" by Mike Dawson

Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Nutch Wiki" for change notification.

The following page has been changed by Mike Dawson:
http://wiki.apache.org/nutch/AddingNewLocalization

New page:
===Adding a New Language to Nutch===

If you want to have Nutch in your language - hopefully the below helps.  I just Googled around.

* Unzip Nutch 1.0 to any folder

* Translate the .properties files that you find in src/web/locale/org/nutch/jsp :
** For each file make sure that you have your own version ending in _<langcode>.properties e.g. _fa.properties .  Btw OmegaT is an excellent Translation memory program to help with standardizing terms etc.

* Make a folder src/web/include/<langcode> with a file header.xml - again this needs translated.
* Make a folder src/web/pages/<langcode> and copy the .xml files from the English folder and then translate them.  In search.xml look for the line:
<pre>
<input type="hidden" name="lang" value="fa"/>
</pre>
Change the value of lang to match the language you are adding (e.g. fa)

* Add your language to src/web/include/footer.html

* In the Nutch base directory run ant

<pre>
ant generate-docs
</pre>

* Work in progress - I now find that when doing the search it still comes back in English... for some reason it seems like the JSP loads the resource bundle according to the language passed by the browser headers, not according to the lang parameter...