Search code examples
jsonwikipedia-apinon-latin

Wikipedia API for nan latin scripts


I am using wikipedia api to get json from a specific title and parsing it in my webpage. I want to add language translator like wiki does but all the non latin scripts like greek,chinese,japanese,hebrew etc are not working.It is perfectly working for other languages like french,german etc.

I am adding abbreviations for language like en for english,el for greek etc to the front of link wikipedia.org/wiki and adding search title at the end of the link.

for ex: if user provides albert einstein as title and greek as language,then the link would be http://el.wikipedia.org/wiki/albert%20einstein.


Solution

  • The problem is that the page title for Albert Einstein in Greek is Άλμπερτ Αϊνστάιν.

    If you know the right title in English, you might consider finding the English page, and then use interwiki links (prop=iwlinks in the API) to find the title in Greek, or any other language.