YAML या JSON में भाषा कोड की सूची? [बन्द है]


85

वहाँ कहीं बाहर YAML या JSON में भाषा कोड की एक सूची है ?

एक और प्रारूप ठीक है, यदि आवश्यक हो तो मैं इसे परिवर्तित कर सकता हूं।


5
विकिपीडिया / HTML प्रारूप के बारे में कैसे? :)
एड्रियन

2
हां मशीन को पठनीय होना चाहिए या नहीं? विकिपीडिया पर कुछ अधिक नियमित जानकारी को डीबीपीडिया से मशीन-पठनीय तरीके से एक्सेस किया जा सकता है ।
हिप्पिट्रैएल

1
इस प्रश्न को देखने वाले लोगों को भी मुक्त ध्वज चिह्न में रुचि हो सकती है ।
मार्टिन थोमा

HTML और XML में W3C भाषा टैग के अनुसार , सूची IANA भाषा सबटैग रजिस्ट्री पर आधारित होनी चाहिए जो 8,000 से अधिक भाषाओं और 300 क्षेत्रों में सूचीबद्ध है।
RobG

2
एक भाषा सूची यहाँ CSV या JSON data.okfn.org/data/core/language-codes के रूप में उपलब्ध है ।
मटर

जवाबों:


191
/**
 * @author Phil Teare
 * using wikipedia data
 */
isoLangs = {
    "ab":{
        "name":"Abkhaz",
        "nativeName":"аҧсуа"
    },
    "aa":{
        "name":"Afar",
        "nativeName":"Afaraf"
    },
    "af":{
        "name":"Afrikaans",
        "nativeName":"Afrikaans"
    },
    "ak":{
        "name":"Akan",
        "nativeName":"Akan"
    },
    "sq":{
        "name":"Albanian",
        "nativeName":"Shqip"
    },
    "am":{
        "name":"Amharic",
        "nativeName":"አማርኛ"
    },
    "ar":{
        "name":"Arabic",
        "nativeName":"العربية"
    },
    "an":{
        "name":"Aragonese",
        "nativeName":"Aragonés"
    },
    "hy":{
        "name":"Armenian",
        "nativeName":"Հայերեն"
    },
    "as":{
        "name":"Assamese",
        "nativeName":"অসমীয়া"
    },
    "av":{
        "name":"Avaric",
        "nativeName":"авар мацӀ, магӀарул мацӀ"
    },
    "ae":{
        "name":"Avestan",
        "nativeName":"avesta"
    },
    "ay":{
        "name":"Aymara",
        "nativeName":"aymar aru"
    },
    "az":{
        "name":"Azerbaijani",
        "nativeName":"azərbaycan dili"
    },
    "bm":{
        "name":"Bambara",
        "nativeName":"bamanankan"
    },
    "ba":{
        "name":"Bashkir",
        "nativeName":"башҡорт теле"
    },
    "eu":{
        "name":"Basque",
        "nativeName":"euskara, euskera"
    },
    "be":{
        "name":"Belarusian",
        "nativeName":"Беларуская"
    },
    "bn":{
        "name":"Bengali",
        "nativeName":"বাংলা"
    },
    "bh":{
        "name":"Bihari",
        "nativeName":"भोजपुरी"
    },
    "bi":{
        "name":"Bislama",
        "nativeName":"Bislama"
    },
    "bs":{
        "name":"Bosnian",
        "nativeName":"bosanski jezik"
    },
    "br":{
        "name":"Breton",
        "nativeName":"brezhoneg"
    },
    "bg":{
        "name":"Bulgarian",
        "nativeName":"български език"
    },
    "my":{
        "name":"Burmese",
        "nativeName":"ဗမာစာ"
    },
    "ca":{
        "name":"Catalan; Valencian",
        "nativeName":"Català"
    },
    "ch":{
        "name":"Chamorro",
        "nativeName":"Chamoru"
    },
    "ce":{
        "name":"Chechen",
        "nativeName":"нохчийн мотт"
    },
    "ny":{
        "name":"Chichewa; Chewa; Nyanja",
        "nativeName":"chiCheŵa, chinyanja"
    },
    "zh":{
        "name":"Chinese",
        "nativeName":"中文 (Zhōngwén), 汉语, 漢語"
    },
    "cv":{
        "name":"Chuvash",
        "nativeName":"чӑваш чӗлхи"
    },
    "kw":{
        "name":"Cornish",
        "nativeName":"Kernewek"
    },
    "co":{
        "name":"Corsican",
        "nativeName":"corsu, lingua corsa"
    },
    "cr":{
        "name":"Cree",
        "nativeName":"ᓀᐦᐃᔭᐍᐏᐣ"
    },
    "hr":{
        "name":"Croatian",
        "nativeName":"hrvatski"
    },
    "cs":{
        "name":"Czech",
        "nativeName":"česky, čeština"
    },
    "da":{
        "name":"Danish",
        "nativeName":"dansk"
    },
    "dv":{
        "name":"Divehi; Dhivehi; Maldivian;",
        "nativeName":"ދިވެހި"
    },
    "nl":{
        "name":"Dutch",
        "nativeName":"Nederlands, Vlaams"
    },
    "en":{
        "name":"English",
        "nativeName":"English"
    },
    "eo":{
        "name":"Esperanto",
        "nativeName":"Esperanto"
    },
    "et":{
        "name":"Estonian",
        "nativeName":"eesti, eesti keel"
    },
    "ee":{
        "name":"Ewe",
        "nativeName":"Eʋegbe"
    },
    "fo":{
        "name":"Faroese",
        "nativeName":"føroyskt"
    },
    "fj":{
        "name":"Fijian",
        "nativeName":"vosa Vakaviti"
    },
    "fi":{
        "name":"Finnish",
        "nativeName":"suomi, suomen kieli"
    },
    "fr":{
        "name":"French",
        "nativeName":"français, langue française"
    },
    "ff":{
        "name":"Fula; Fulah; Pulaar; Pular",
        "nativeName":"Fulfulde, Pulaar, Pular"
    },
    "gl":{
        "name":"Galician",
        "nativeName":"Galego"
    },
    "ka":{
        "name":"Georgian",
        "nativeName":"ქართული"
    },
    "de":{
        "name":"German",
        "nativeName":"Deutsch"
    },
    "el":{
        "name":"Greek, Modern",
        "nativeName":"Ελληνικά"
    },
    "gn":{
        "name":"Guaraní",
        "nativeName":"Avañeẽ"
    },
    "gu":{
        "name":"Gujarati",
        "nativeName":"ગુજરાતી"
    },
    "ht":{
        "name":"Haitian; Haitian Creole",
        "nativeName":"Kreyòl ayisyen"
    },
    "ha":{
        "name":"Hausa",
        "nativeName":"Hausa, هَوُسَ"
    },
    "he":{
        "name":"Hebrew (modern)",
        "nativeName":"עברית"
    },
    "hz":{
        "name":"Herero",
        "nativeName":"Otjiherero"
    },
    "hi":{
        "name":"Hindi",
        "nativeName":"हिन्दी, हिंदी"
    },
    "ho":{
        "name":"Hiri Motu",
        "nativeName":"Hiri Motu"
    },
    "hu":{
        "name":"Hungarian",
        "nativeName":"Magyar"
    },
    "ia":{
        "name":"Interlingua",
        "nativeName":"Interlingua"
    },
    "id":{
        "name":"Indonesian",
        "nativeName":"Bahasa Indonesia"
    },
    "ie":{
        "name":"Interlingue",
        "nativeName":"Originally called Occidental; then Interlingue after WWII"
    },
    "ga":{
        "name":"Irish",
        "nativeName":"Gaeilge"
    },
    "ig":{
        "name":"Igbo",
        "nativeName":"Asụsụ Igbo"
    },
    "ik":{
        "name":"Inupiaq",
        "nativeName":"Iñupiaq, Iñupiatun"
    },
    "io":{
        "name":"Ido",
        "nativeName":"Ido"
    },
    "is":{
        "name":"Icelandic",
        "nativeName":"Íslenska"
    },
    "it":{
        "name":"Italian",
        "nativeName":"Italiano"
    },
    "iu":{
        "name":"Inuktitut",
        "nativeName":"ᐃᓄᒃᑎᑐᑦ"
    },
    "ja":{
        "name":"Japanese",
        "nativeName":"日本語 (にほんご/にっぽんご)"
    },
    "jv":{
        "name":"Javanese",
        "nativeName":"basa Jawa"
    },
    "kl":{
        "name":"Kalaallisut, Greenlandic",
        "nativeName":"kalaallisut, kalaallit oqaasii"
    },
    "kn":{
        "name":"Kannada",
        "nativeName":"ಕನ್ನಡ"
    },
    "kr":{
        "name":"Kanuri",
        "nativeName":"Kanuri"
    },
    "ks":{
        "name":"Kashmiri",
        "nativeName":"कश्मीरी, كشميري‎"
    },
    "kk":{
        "name":"Kazakh",
        "nativeName":"Қазақ тілі"
    },
    "km":{
        "name":"Khmer",
        "nativeName":"ភាសាខ្មែរ"
    },
    "ki":{
        "name":"Kikuyu, Gikuyu",
        "nativeName":"Gĩkũyũ"
    },
    "rw":{
        "name":"Kinyarwanda",
        "nativeName":"Ikinyarwanda"
    },
    "ky":{
        "name":"Kirghiz, Kyrgyz",
        "nativeName":"кыргыз тили"
    },
    "kv":{
        "name":"Komi",
        "nativeName":"коми кыв"
    },
    "kg":{
        "name":"Kongo",
        "nativeName":"KiKongo"
    },
    "ko":{
        "name":"Korean",
        "nativeName":"한국어 (韓國語), 조선말 (朝鮮語)"
    },
    "ku":{
        "name":"Kurdish",
        "nativeName":"Kurdî, كوردی‎"
    },
    "kj":{
        "name":"Kwanyama, Kuanyama",
        "nativeName":"Kuanyama"
    },
    "la":{
        "name":"Latin",
        "nativeName":"latine, lingua latina"
    },
    "lb":{
        "name":"Luxembourgish, Letzeburgesch",
        "nativeName":"Lëtzebuergesch"
    },
    "lg":{
        "name":"Luganda",
        "nativeName":"Luganda"
    },
    "li":{
        "name":"Limburgish, Limburgan, Limburger",
        "nativeName":"Limburgs"
    },
    "ln":{
        "name":"Lingala",
        "nativeName":"Lingála"
    },
    "lo":{
        "name":"Lao",
        "nativeName":"ພາສາລາວ"
    },
    "lt":{
        "name":"Lithuanian",
        "nativeName":"lietuvių kalba"
    },
    "lu":{
        "name":"Luba-Katanga",
        "nativeName":""
    },
    "lv":{
        "name":"Latvian",
        "nativeName":"latviešu valoda"
    },
    "gv":{
        "name":"Manx",
        "nativeName":"Gaelg, Gailck"
    },
    "mk":{
        "name":"Macedonian",
        "nativeName":"македонски јазик"
    },
    "mg":{
        "name":"Malagasy",
        "nativeName":"Malagasy fiteny"
    },
    "ms":{
        "name":"Malay",
        "nativeName":"bahasa Melayu, بهاس ملايو‎"
    },
    "ml":{
        "name":"Malayalam",
        "nativeName":"മലയാളം"
    },
    "mt":{
        "name":"Maltese",
        "nativeName":"Malti"
    },
    "mi":{
        "name":"Māori",
        "nativeName":"te reo Māori"
    },
    "mr":{
        "name":"Marathi (Marāṭhī)",
        "nativeName":"मराठी"
    },
    "mh":{
        "name":"Marshallese",
        "nativeName":"Kajin M̧ajeļ"
    },
    "mn":{
        "name":"Mongolian",
        "nativeName":"монгол"
    },
    "na":{
        "name":"Nauru",
        "nativeName":"Ekakairũ Naoero"
    },
    "nv":{
        "name":"Navajo, Navaho",
        "nativeName":"Diné bizaad, Dinékʼehǰí"
    },
    "nb":{
        "name":"Norwegian Bokmål",
        "nativeName":"Norsk bokmål"
    },
    "nd":{
        "name":"North Ndebele",
        "nativeName":"isiNdebele"
    },
    "ne":{
        "name":"Nepali",
        "nativeName":"नेपाली"
    },
    "ng":{
        "name":"Ndonga",
        "nativeName":"Owambo"
    },
    "nn":{
        "name":"Norwegian Nynorsk",
        "nativeName":"Norsk nynorsk"
    },
    "no":{
        "name":"Norwegian",
        "nativeName":"Norsk"
    },
    "ii":{
        "name":"Nuosu",
        "nativeName":"ꆈꌠ꒿ Nuosuhxop"
    },
    "nr":{
        "name":"South Ndebele",
        "nativeName":"isiNdebele"
    },
    "oc":{
        "name":"Occitan",
        "nativeName":"Occitan"
    },
    "oj":{
        "name":"Ojibwe, Ojibwa",
        "nativeName":"ᐊᓂᔑᓈᐯᒧᐎᓐ"
    },
    "cu":{
        "name":"Old Church Slavonic, Church Slavic, Church Slavonic, Old Bulgarian, Old Slavonic",
        "nativeName":"ѩзыкъ словѣньскъ"
    },
    "om":{
        "name":"Oromo",
        "nativeName":"Afaan Oromoo"
    },
    "or":{
        "name":"Oriya",
        "nativeName":"ଓଡ଼ିଆ"
    },
    "os":{
        "name":"Ossetian, Ossetic",
        "nativeName":"ирон æвзаг"
    },
    "pa":{
        "name":"Panjabi, Punjabi",
        "nativeName":"ਪੰਜਾਬੀ, پنجابی‎"
    },
    "pi":{
        "name":"Pāli",
        "nativeName":"पाऴि"
    },
    "fa":{
        "name":"Persian",
        "nativeName":"فارسی"
    },
    "pl":{
        "name":"Polish",
        "nativeName":"polski"
    },
    "ps":{
        "name":"Pashto, Pushto",
        "nativeName":"پښتو"
    },
    "pt":{
        "name":"Portuguese",
        "nativeName":"Português"
    },
    "qu":{
        "name":"Quechua",
        "nativeName":"Runa Simi, Kichwa"
    },
    "rm":{
        "name":"Romansh",
        "nativeName":"rumantsch grischun"
    },
    "rn":{
        "name":"Kirundi",
        "nativeName":"kiRundi"
    },
    "ro":{
        "name":"Romanian, Moldavian, Moldovan",
        "nativeName":"română"
    },
    "ru":{
        "name":"Russian",
        "nativeName":"русский язык"
    },
    "sa":{
        "name":"Sanskrit (Saṁskṛta)",
        "nativeName":"संस्कृतम्"
    },
    "sc":{
        "name":"Sardinian",
        "nativeName":"sardu"
    },
    "sd":{
        "name":"Sindhi",
        "nativeName":"सिन्धी, سنڌي، سندھی‎"
    },
    "se":{
        "name":"Northern Sami",
        "nativeName":"Davvisámegiella"
    },
    "sm":{
        "name":"Samoan",
        "nativeName":"gagana faa Samoa"
    },
    "sg":{
        "name":"Sango",
        "nativeName":"yângâ  sängö"
    },
    "sr":{
        "name":"Serbian",
        "nativeName":"српски језик"
    },
    "gd":{
        "name":"Scottish Gaelic; Gaelic",
        "nativeName":"Gàidhlig"
    },
    "sn":{
        "name":"Shona",
        "nativeName":"chiShona"
    },
    "si":{
        "name":"Sinhala, Sinhalese",
        "nativeName":"සිංහල"
    },
    "sk":{
        "name":"Slovak",
        "nativeName":"slovenčina"
    },
    "sl":{
        "name":"Slovene",
        "nativeName":"slovenščina"
    },
    "so":{
        "name":"Somali",
        "nativeName":"Soomaaliga, af Soomaali"
    },
    "st":{
        "name":"Southern Sotho",
        "nativeName":"Sesotho"
    },
    "es":{
        "name":"Spanish; Castilian",
        "nativeName":"español, castellano"
    },
    "su":{
        "name":"Sundanese",
        "nativeName":"Basa Sunda"
    },
    "sw":{
        "name":"Swahili",
        "nativeName":"Kiswahili"
    },
    "ss":{
        "name":"Swati",
        "nativeName":"SiSwati"
    },
    "sv":{
        "name":"Swedish",
        "nativeName":"svenska"
    },
    "ta":{
        "name":"Tamil",
        "nativeName":"தமிழ்"
    },
    "te":{
        "name":"Telugu",
        "nativeName":"తెలుగు"
    },
    "tg":{
        "name":"Tajik",
        "nativeName":"тоҷикӣ, toğikī, تاجیکی‎"
    },
    "th":{
        "name":"Thai",
        "nativeName":"ไทย"
    },
    "ti":{
        "name":"Tigrinya",
        "nativeName":"ትግርኛ"
    },
    "bo":{
        "name":"Tibetan Standard, Tibetan, Central",
        "nativeName":"བོད་ཡིག"
    },
    "tk":{
        "name":"Turkmen",
        "nativeName":"Türkmen, Түркмен"
    },
    "tl":{
        "name":"Tagalog",
        "nativeName":"Wikang Tagalog, ᜏᜒᜃᜅ᜔ ᜆᜄᜎᜓᜄ᜔"
    },
    "tn":{
        "name":"Tswana",
        "nativeName":"Setswana"
    },
    "to":{
        "name":"Tonga (Tonga Islands)",
        "nativeName":"faka Tonga"
    },
    "tr":{
        "name":"Turkish",
        "nativeName":"Türkçe"
    },
    "ts":{
        "name":"Tsonga",
        "nativeName":"Xitsonga"
    },
    "tt":{
        "name":"Tatar",
        "nativeName":"татарча, tatarça, تاتارچا‎"
    },
    "tw":{
        "name":"Twi",
        "nativeName":"Twi"
    },
    "ty":{
        "name":"Tahitian",
        "nativeName":"Reo Tahiti"
    },
    "ug":{
        "name":"Uighur, Uyghur",
        "nativeName":"Uyƣurqə, ئۇيغۇرچە‎"
    },
    "uk":{
        "name":"Ukrainian",
        "nativeName":"українська"
    },
    "ur":{
        "name":"Urdu",
        "nativeName":"اردو"
    },
    "uz":{
        "name":"Uzbek",
        "nativeName":"zbek, Ўзбек, أۇزبېك‎"
    },
    "ve":{
        "name":"Venda",
        "nativeName":"Tshivenḓa"
    },
    "vi":{
        "name":"Vietnamese",
        "nativeName":"Tiếng Việt"
    },
    "vo":{
        "name":"Volapük",
        "nativeName":"Volapük"
    },
    "wa":{
        "name":"Walloon",
        "nativeName":"Walon"
    },
    "cy":{
        "name":"Welsh",
        "nativeName":"Cymraeg"
    },
    "wo":{
        "name":"Wolof",
        "nativeName":"Wollof"
    },
    "fy":{
        "name":"Western Frisian",
        "nativeName":"Frysk"
    },
    "xh":{
        "name":"Xhosa",
        "nativeName":"isiXhosa"
    },
    "yi":{
        "name":"Yiddish",
        "nativeName":"ייִדיש"
    },
    "yo":{
        "name":"Yoruba",
        "nativeName":"Yorùbá"
    },
    "za":{
        "name":"Zhuang, Chuang",
        "nativeName":"Saɯ cueŋƅ, Saw cuengh"
    }
}

19
आसान नकल करने और चिपकाने के लिए उपलब्ध इसी जसन का कच्चा संस्करण: pastebin.com/raw.php?i=ppdMS687
Eric S. Bullington

: गलती से एक त्रुटि पाया उज (उज़्बेक) नहीं है zbek लेकिन O'zbekcha
18446744073709551615

3
कोई चीनी पारंपरिक?
टूलकिट

8
एक भाषा सूची यहाँ CSV या JSON data.okfn.org/data/core/language-codes के रूप में उपलब्ध है ।
मटर

1
क्या आप जानते हैं कि विभिन्न भाषाओं (जर्मन / फ्रेंश / आदि?) के लिए ऐसी सूचियाँ कहाँ से मिल सकती हैं
एडम

97

जुलियोनोमेरा और instine के उत्तर विलीन हो गए:

 [
      {"code":"ab","name":"Abkhaz","nativeName":"аҧсуа"},
      {"code":"aa","name":"Afar","nativeName":"Afaraf"},
      {"code":"af","name":"Afrikaans","nativeName":"Afrikaans"},
      {"code":"ak","name":"Akan","nativeName":"Akan"},
      {"code":"sq","name":"Albanian","nativeName":"Shqip"},
      {"code":"am","name":"Amharic","nativeName":"አማርኛ"},
      {"code":"ar","name":"Arabic","nativeName":"العربية"},
      {"code":"an","name":"Aragonese","nativeName":"Aragonés"},
      {"code":"hy","name":"Armenian","nativeName":"Հայերեն"},
      {"code":"as","name":"Assamese","nativeName":"অসমীয়া"},
      {"code":"av","name":"Avaric","nativeName":"авар мацӀ, магӀарул мацӀ"},
      {"code":"ae","name":"Avestan","nativeName":"avesta"},
      {"code":"ay","name":"Aymara","nativeName":"aymar aru"},
      {"code":"az","name":"Azerbaijani","nativeName":"azərbaycan dili"},
      {"code":"bm","name":"Bambara","nativeName":"bamanankan"},
      {"code":"ba","name":"Bashkir","nativeName":"башҡорт теле"},
      {"code":"eu","name":"Basque","nativeName":"euskara, euskera"},
      {"code":"be","name":"Belarusian","nativeName":"Беларуская"},
      {"code":"bn","name":"Bengali","nativeName":"বাংলা"},
      {"code":"bh","name":"Bihari","nativeName":"भोजपुरी"},
      {"code":"bi","name":"Bislama","nativeName":"Bislama"},
      {"code":"bs","name":"Bosnian","nativeName":"bosanski jezik"},
      {"code":"br","name":"Breton","nativeName":"brezhoneg"},
      {"code":"bg","name":"Bulgarian","nativeName":"български език"},
      {"code":"my","name":"Burmese","nativeName":"ဗမာစာ"},
      {"code":"ca","name":"Catalan; Valencian","nativeName":"Català"},
      {"code":"ch","name":"Chamorro","nativeName":"Chamoru"},
      {"code":"ce","name":"Chechen","nativeName":"нохчийн мотт"},
      {"code":"ny","name":"Chichewa; Chewa; Nyanja","nativeName":"chiCheŵa, chinyanja"},
      {"code":"zh","name":"Chinese","nativeName":"中文 (Zhōngwén), 汉语, 漢語"},
      {"code":"cv","name":"Chuvash","nativeName":"чӑваш чӗлхи"},
      {"code":"kw","name":"Cornish","nativeName":"Kernewek"},
      {"code":"co","name":"Corsican","nativeName":"corsu, lingua corsa"},
      {"code":"cr","name":"Cree","nativeName":"ᓀᐦᐃᔭᐍᐏᐣ"},
      {"code":"hr","name":"Croatian","nativeName":"hrvatski"},
      {"code":"cs","name":"Czech","nativeName":"česky, čeština"},
      {"code":"da","name":"Danish","nativeName":"dansk"},
      {"code":"dv","name":"Divehi; Dhivehi; Maldivian;","nativeName":"ދިވެހި"},
      {"code":"nl","name":"Dutch","nativeName":"Nederlands, Vlaams"},
      {"code":"en","name":"English","nativeName":"English"},
      {"code":"eo","name":"Esperanto","nativeName":"Esperanto"},
      {"code":"et","name":"Estonian","nativeName":"eesti, eesti keel"},
      {"code":"ee","name":"Ewe","nativeName":"Eʋegbe"},
      {"code":"fo","name":"Faroese","nativeName":"føroyskt"},
      {"code":"fj","name":"Fijian","nativeName":"vosa Vakaviti"},
      {"code":"fi","name":"Finnish","nativeName":"suomi, suomen kieli"},
      {"code":"fr","name":"French","nativeName":"français, langue française"},
      {"code":"ff","name":"Fula; Fulah; Pulaar; Pular","nativeName":"Fulfulde, Pulaar, Pular"},
      {"code":"gl","name":"Galician","nativeName":"Galego"},
      {"code":"ka","name":"Georgian","nativeName":"ქართული"},
      {"code":"de","name":"German","nativeName":"Deutsch"},
      {"code":"el","name":"Greek, Modern","nativeName":"Ελληνικά"},
      {"code":"gn","name":"Guaraní","nativeName":"Avañeẽ"},
      {"code":"gu","name":"Gujarati","nativeName":"ગુજરાતી"},
      {"code":"ht","name":"Haitian; Haitian Creole","nativeName":"Kreyòl ayisyen"},
      {"code":"ha","name":"Hausa","nativeName":"Hausa, هَوُسَ"},
      {"code":"he","name":"Hebrew (modern)","nativeName":"עברית"},
      {"code":"hz","name":"Herero","nativeName":"Otjiherero"},
      {"code":"hi","name":"Hindi","nativeName":"हिन्दी, हिंदी"},
      {"code":"ho","name":"Hiri Motu","nativeName":"Hiri Motu"},
      {"code":"hu","name":"Hungarian","nativeName":"Magyar"},
      {"code":"ia","name":"Interlingua","nativeName":"Interlingua"},
      {"code":"id","name":"Indonesian","nativeName":"Bahasa Indonesia"},
      {"code":"ie","name":"Interlingue","nativeName":"Originally called Occidental; then Interlingue after WWII"},
      {"code":"ga","name":"Irish","nativeName":"Gaeilge"},
      {"code":"ig","name":"Igbo","nativeName":"Asụsụ Igbo"},
      {"code":"ik","name":"Inupiaq","nativeName":"Iñupiaq, Iñupiatun"},
      {"code":"io","name":"Ido","nativeName":"Ido"},
      {"code":"is","name":"Icelandic","nativeName":"Íslenska"},
      {"code":"it","name":"Italian","nativeName":"Italiano"},
      {"code":"iu","name":"Inuktitut","nativeName":"ᐃᓄᒃᑎᑐᑦ"},
      {"code":"ja","name":"Japanese","nativeName":"日本語 (にほんご/にっぽんご)"},
      {"code":"jv","name":"Javanese","nativeName":"basa Jawa"},
      {"code":"kl","name":"Kalaallisut, Greenlandic","nativeName":"kalaallisut, kalaallit oqaasii"},
      {"code":"kn","name":"Kannada","nativeName":"ಕನ್ನಡ"},
      {"code":"kr","name":"Kanuri","nativeName":"Kanuri"},
      {"code":"ks","name":"Kashmiri","nativeName":"कश्मीरी, كشميري‎"},
      {"code":"kk","name":"Kazakh","nativeName":"Қазақ тілі"},
      {"code":"km","name":"Khmer","nativeName":"ភាសាខ្មែរ"},
      {"code":"ki","name":"Kikuyu, Gikuyu","nativeName":"Gĩkũyũ"},
      {"code":"rw","name":"Kinyarwanda","nativeName":"Ikinyarwanda"},
      {"code":"ky","name":"Kirghiz, Kyrgyz","nativeName":"кыргыз тили"},
      {"code":"kv","name":"Komi","nativeName":"коми кыв"},
      {"code":"kg","name":"Kongo","nativeName":"KiKongo"},
      {"code":"ko","name":"Korean","nativeName":"한국어 (韓國語), 조선말 (朝鮮語)"},
      {"code":"ku","name":"Kurdish","nativeName":"Kurdî, كوردی‎"},
      {"code":"kj","name":"Kwanyama, Kuanyama","nativeName":"Kuanyama"},
      {"code":"la","name":"Latin","nativeName":"latine, lingua latina"},
      {"code":"lb","name":"Luxembourgish, Letzeburgesch","nativeName":"Lëtzebuergesch"},
      {"code":"lg","name":"Luganda","nativeName":"Luganda"},
      {"code":"li","name":"Limburgish, Limburgan, Limburger","nativeName":"Limburgs"},
      {"code":"ln","name":"Lingala","nativeName":"Lingála"},
      {"code":"lo","name":"Lao","nativeName":"ພາສາລາວ"},
      {"code":"lt","name":"Lithuanian","nativeName":"lietuvių kalba"},
      {"code":"lu","name":"Luba-Katanga","nativeName":""},
      {"code":"lv","name":"Latvian","nativeName":"latviešu valoda"},
      {"code":"gv","name":"Manx","nativeName":"Gaelg, Gailck"},
      {"code":"mk","name":"Macedonian","nativeName":"македонски јазик"},
      {"code":"mg","name":"Malagasy","nativeName":"Malagasy fiteny"},
      {"code":"ms","name":"Malay","nativeName":"bahasa Melayu, بهاس ملايو‎"},
      {"code":"ml","name":"Malayalam","nativeName":"മലയാളം"},
      {"code":"mt","name":"Maltese","nativeName":"Malti"},
      {"code":"mi","name":"Māori","nativeName":"te reo Māori"},
      {"code":"mr","name":"Marathi (Marāṭhī)","nativeName":"मराठी"},
      {"code":"mh","name":"Marshallese","nativeName":"Kajin M̧ajeļ"},
      {"code":"mn","name":"Mongolian","nativeName":"монгол"},
      {"code":"na","name":"Nauru","nativeName":"Ekakairũ Naoero"},
      {"code":"nv","name":"Navajo, Navaho","nativeName":"Diné bizaad, Dinékʼehǰí"},
      {"code":"nb","name":"Norwegian Bokmål","nativeName":"Norsk bokmål"},
      {"code":"nd","name":"North Ndebele","nativeName":"isiNdebele"},
      {"code":"ne","name":"Nepali","nativeName":"नेपाली"},
      {"code":"ng","name":"Ndonga","nativeName":"Owambo"},
      {"code":"nn","name":"Norwegian Nynorsk","nativeName":"Norsk nynorsk"},
      {"code":"no","name":"Norwegian","nativeName":"Norsk"},
      {"code":"ii","name":"Nuosu","nativeName":"ꆈꌠ꒿ Nuosuhxop"},
      {"code":"nr","name":"South Ndebele","nativeName":"isiNdebele"},
      {"code":"oc","name":"Occitan","nativeName":"Occitan"},
      {"code":"oj","name":"Ojibwe, Ojibwa","nativeName":"ᐊᓂᔑᓈᐯᒧᐎᓐ"},
      {"code":"cu","name":"Old Church Slavonic, Church Slavic, Church Slavonic, Old Bulgarian, Old Slavonic","nativeName":"ѩзыкъ словѣньскъ"},
      {"code":"om","name":"Oromo","nativeName":"Afaan Oromoo"},
      {"code":"or","name":"Oriya","nativeName":"ଓଡ଼ିଆ"},
      {"code":"os","name":"Ossetian, Ossetic","nativeName":"ирон æвзаг"},
      {"code":"pa","name":"Panjabi, Punjabi","nativeName":"ਪੰਜਾਬੀ, پنجابی‎"},
      {"code":"pi","name":"Pāli","nativeName":"पाऴि"},
      {"code":"fa","name":"Persian","nativeName":"فارسی"},
      {"code":"pl","name":"Polish","nativeName":"polski"},
      {"code":"ps","name":"Pashto, Pushto","nativeName":"پښتو"},
      {"code":"pt","name":"Portuguese","nativeName":"Português"},
      {"code":"qu","name":"Quechua","nativeName":"Runa Simi, Kichwa"},
      {"code":"rm","name":"Romansh","nativeName":"rumantsch grischun"},
      {"code":"rn","name":"Kirundi","nativeName":"kiRundi"},
      {"code":"ro","name":"Romanian, Moldavian, Moldovan","nativeName":"română"},
      {"code":"ru","name":"Russian","nativeName":"русский язык"},
      {"code":"sa","name":"Sanskrit (Saṁskṛta)","nativeName":"संस्कृतम्"},
      {"code":"sc","name":"Sardinian","nativeName":"sardu"},
      {"code":"sd","name":"Sindhi","nativeName":"सिन्धी, سنڌي، سندھی‎"},
      {"code":"se","name":"Northern Sami","nativeName":"Davvisámegiella"},
      {"code":"sm","name":"Samoan","nativeName":"gagana faa Samoa"},
      {"code":"sg","name":"Sango","nativeName":"yângâ  sängö"},
      {"code":"sr","name":"Serbian","nativeName":"српски језик"},
      {"code":"gd","name":"Scottish Gaelic; Gaelic","nativeName":"Gàidhlig"},
      {"code":"sn","name":"Shona","nativeName":"chiShona"},
      {"code":"si","name":"Sinhala, Sinhalese","nativeName":"සිංහල"},
      {"code":"sk","name":"Slovak","nativeName":"slovenčina"},
      {"code":"sl","name":"Slovene","nativeName":"slovenščina"},
      {"code":"so","name":"Somali","nativeName":"Soomaaliga, af Soomaali"},
      {"code":"st","name":"Southern Sotho","nativeName":"Sesotho"},
      {"code":"es","name":"Spanish; Castilian","nativeName":"español, castellano"},
      {"code":"su","name":"Sundanese","nativeName":"Basa Sunda"},
      {"code":"sw","name":"Swahili","nativeName":"Kiswahili"},
      {"code":"ss","name":"Swati","nativeName":"SiSwati"},
      {"code":"sv","name":"Swedish","nativeName":"svenska"},
      {"code":"ta","name":"Tamil","nativeName":"தமிழ்"},
      {"code":"te","name":"Telugu","nativeName":"తెలుగు"},
      {"code":"tg","name":"Tajik","nativeName":"тоҷикӣ, toğikī, تاجیکی‎"},
      {"code":"th","name":"Thai","nativeName":"ไทย"},
      {"code":"ti","name":"Tigrinya","nativeName":"ትግርኛ"},
      {"code":"bo","name":"Tibetan Standard, Tibetan, Central","nativeName":"བོད་ཡིག"},
      {"code":"tk","name":"Turkmen","nativeName":"Türkmen, Түркмен"},
      {"code":"tl","name":"Tagalog","nativeName":"Wikang Tagalog, ᜏᜒᜃᜅ᜔ ᜆᜄᜎᜓᜄ᜔"},
      {"code":"tn","name":"Tswana","nativeName":"Setswana"},
      {"code":"to","name":"Tonga (Tonga Islands)","nativeName":"faka Tonga"},
      {"code":"tr","name":"Turkish","nativeName":"Türkçe"},
      {"code":"ts","name":"Tsonga","nativeName":"Xitsonga"},
      {"code":"tt","name":"Tatar","nativeName":"татарча, tatarça, تاتارچا‎"},
      {"code":"tw","name":"Twi","nativeName":"Twi"},
      {"code":"ty","name":"Tahitian","nativeName":"Reo Tahiti"},
      {"code":"ug","name":"Uighur, Uyghur","nativeName":"Uyƣurqə, ئۇيغۇرچە‎"},
      {"code":"uk","name":"Ukrainian","nativeName":"українська"},
      {"code":"ur","name":"Urdu","nativeName":"اردو"},
      {"code":"uz","name":"Uzbek","nativeName":"zbek, Ўзбек, أۇزبېك‎"},
      {"code":"ve","name":"Venda","nativeName":"Tshivenḓa"},
      {"code":"vi","name":"Vietnamese","nativeName":"Tiếng Việt"},
      {"code":"vo","name":"Volapük","nativeName":"Volapük"},
      {"code":"wa","name":"Walloon","nativeName":"Walon"},
      {"code":"cy","name":"Welsh","nativeName":"Cymraeg"},
      {"code":"wo","name":"Wolof","nativeName":"Wollof"},
      {"code":"fy","name":"Western Frisian","nativeName":"Frysk"},
      {"code":"xh","name":"Xhosa","nativeName":"isiXhosa"},
      {"code":"yi","name":"Yiddish","nativeName":"ייִדיש"},
      {"code":"yo","name":"Yoruba","nativeName":"Yorùbá"},
      {"code":"za","name":"Zhuang, Chuang","nativeName":"Saɯ cueŋƅ, Saw cuengh"}
    ]

क्या किसी के पास दिनांक-प्रारूप वाली भाषा सूची है?
अंकुर अकवलिया

हालांकि पूरा नहीं हुआ - 182 आइटम, जब उन्हें 185 होना चाहिए -> पूरी सूची के लिए user9869932 देखें
क्रिश बोन

27

मुझे लगता है कि संयुक्त राष्ट्र या आईएसओ वास्तव में उस सूची को सीएसवी प्रारूप में प्रकाशित करते हैं। वह परम स्रोत होगा।

हालांकि, मुझे यकीन नहीं है कि वे इसे मुफ्त में प्रकाशित करेंगे।

संपादित करें: वास्तव में, लिंक आपके द्वारा लिंक किए गए विकिपीडिया लेख में है। यूएस लाइब्रेरी ऑफ कांग्रेस को आईएसओ द्वारा आधिकारिक पंजीकरण प्राधिकरण नामित किया गया है और वे संपूर्ण, आधिकारिक, अप-टू-डेट सूची को पाठ फ़ाइल को पार्स करने के लिए एक तुच्छ के रूप में प्रकाशित करते हैं।

प्रारूप इस तरह दिखता है:

आरा || ar | अरबी | arabe
आर्क ||| आधिकारिक अरामी (700-300 ईसा पूर्व); शाही अरामी (700-300 ईसा पूर्व) | अरामेन डेम्पायर (700-300 ईसा पूर्व)
आर्ग || एक | Aragonese | aragonais
हाथ | हाय | hy | अर्मेनियाई | arménien
अर्न ||| Mapudungun; मापुचे | Mapudungun; मापुचे; mapuce
एआरपी ||| अरापहो | अरापहो
art ||| कृत्रिम भाषाएँ | Artificielles, leses
ARW ||| अरावक | अरावक
एएसएम || रूप में | असमिया | assamais
ast ||| अस्तुरियन; Bable; Leonese; Asturleonese | asturien; Bable; léonais; asturoléonais
Ath ||| अथापस्कैन भाषाएँ | athapascanes, leses

यह 5 क्षेत्र ऊर्ध्वाधर सलाखों से अलग है:

  1. आईएसओ 639-2 अल्फा -3 ग्रंथ सूची कोड
  2. आईएसओ 639-2 अल्फा -3 शब्दावली कोड
  3. आईएसओ 639-1 अल्फा -2 कोड
  4. अंग्रेजी भाषा का नाम
  5. फ्रेंच भाषा का नाम

तो, यह है सीएसवी प्रारूप में वास्तव में, यदि आप की व्याख्या है कि के रूप में चरित्र अलग मान के बजाय कॉमा सेपरेटेड वैल्यूज़ , जो सबसे सीएसवी पारसर्स आप करते हैं।


कोई भी JSON कर सकता है?
टूलकिट

4

यह आपके द्वारा अपने प्रश्न में पोस्ट किए गए लिंक के माध्यम से HTML में उपलब्ध है :) गंभीर रूप से, अगर विकिपीडिया में वह सूची पूरी हो गई है, तो इसे अपनी पसंदीदा भाषा में lxml.html (पायथन में) या किसी अन्य समान लाइब्रेरी का उपयोग करके हड़पना आसान है ।


2
अरे, यह दृष्टिकोण काम करता है। मतदान से पहले एक बेहतर प्रस्ताव दें।
एंड्रे व्लास्लोविच शेख

3
उन लोगों के लिए जो पायथन को पसंद नहीं करते हैं, कुछ और का उपयोग करें। इस प्रश्न में रूबी एक टैग के रूप में है; विकिपीडिया सूची से जो आवश्यक है उसे निकालने के लिए वह भाषा निश्चित रूप से पर्याप्त है। शायद ओपी को एक अलग प्रश्न पोस्ट करना चाहिए: "मैं रूबी (या पसंद की अन्य भाषा) में HTML तालिका से मान कैसे निकालूं?" ;) (और मुझे आश्चर्य नहीं होगा कि अगर स्टैक ओवरफ्लो पर पहले से ही पाया जा सकता है।)
जॉन वाई

4

यहाँ ग्रूवी में एक छोटी सी लिपि है जो एक JSON को सभी भाषाओं के कोड के साथ उनके मूल, अंग्रेजी और पुर्तगाली नामों के साथ प्रिंट करती है।

def en = new Locale("en")
def pt = new Locale("pt")
def nameFor(loc, lang) { loc.getDisplayLanguage(lang).replaceAll(/\S+/){ w -> w.toLowerCase().capitalize()} }

println("export default {")
Locale.getISOLanguages().each{
  def l = new Locale(it)
  println("  $it: {native: '${nameFor(l, l)}', en: '${nameFor(l, en)}', pt: '${nameFor(l, pt)}'},")
}
println("}")

$ groovy langs2json.groovy > languagess.json


4

आप इस JSON को वस्तुओं की सूची के रूप में भी आज़मा सकते हैं:

[
  {
    "code": "ab",
    "name": "Abkhaz"
  },
  {
    "code": "aa",
    "name": "Afar"
  },
  {
    "code": "af",
    "name": "Afrikaans"
  },
  {
    "code": "ak",
    "name": "Akan"
  },
  {
    "code": "sq",
    "name": "Albanian"
  },
  {
    "code": "am",
    "name": "Amharic"
  },
  {
    "code": "ar",
    "name": "Arabic"
  },
  {
    "code": "an",
    "name": "Aragonese"
  },
  {
    "code": "hy",
    "name": "Armenian"
  },
  {
    "code": "as",
    "name": "Assamese"
  },
  {
    "code": "av",
    "name": "Avaric"
  },
  {
    "code": "ae",
    "name": "Avestan"
  },
  {
    "code": "ay",
    "name": "Aymara"
  },
  {
    "code": "az",
    "name": "Azerbaijani"
  },
  {
    "code": "bm",
    "name": "Bambara"
  },
  {
    "code": "ba",
    "name": "Bashkir"
  },
  {
    "code": "eu",
    "name": "Basque"
  },
  {
    "code": "be",
    "name": "Belarusian"
  },
  {
    "code": "bn",
    "name": "Bengali; Bangla"
  },
  {
    "code": "bh",
    "name": "Bihari"
  },
  {
    "code": "bi",
    "name": "Bislama"
  },
  {
    "code": "bs",
    "name": "Bosnian"
  },
  {
    "code": "br",
    "name": "Breton"
  },
  {
    "code": "bg",
    "name": "Bulgarian"
  },
  {
    "code": "my",
    "name": "Burmese"
  },
  {
    "code": "ca",
    "name": "Catalan; Valencian"
  },
  {
    "code": "ch",
    "name": "Chamorro"
  },
  {
    "code": "ce",
    "name": "Chechen"
  },
  {
    "code": "ny",
    "name": "Chichewa; Chewa; Nyanja"
  },
  {
    "code": "zh",
    "name": "Chinese"
  },
  {
    "code": "cv",
    "name": "Chuvash"
  },
  {
    "code": "kw",
    "name": "Cornish"
  },
  {
    "code": "co",
    "name": "Corsican"
  },
  {
    "code": "cr",
    "name": "Cree"
  },
  {
    "code": "hr",
    "name": "Croatian"
  },
  {
    "code": "cs",
    "name": "Czech"
  },
  {
    "code": "da",
    "name": "Danish"
  },
  {
    "code": "dv",
    "name": "Divehi; Dhivehi; Maldivian;"
  },
  {
    "code": "nl",
    "name": "Dutch"
  },
  {
    "code": "dz",
    "name": "Dzongkha"
  },
  {
    "code": "en",
    "name": "English"
  },
  {
    "code": "eo",
    "name": "Esperanto"
  },
  {
    "code": "et",
    "name": "Estonian"
  },
  {
    "code": "ee",
    "name": "Ewe"
  },
  {
    "code": "fo",
    "name": "Faroese"
  },
  {
    "code": "fj",
    "name": "Fijian"
  },
  {
    "code": "fi",
    "name": "Finnish"
  },
  {
    "code": "fr",
    "name": "French"
  },
  {
    "code": "ff",
    "name": "Fula; Fulah; Pulaar; Pular"
  },
  {
    "code": "gl",
    "name": "Galician"
  },
  {
    "code": "ka",
    "name": "Georgian"
  },
  {
    "code": "de",
    "name": "German"
  },
  {
    "code": "el",
    "name": "Greek, Modern"
  },
  {
    "code": "gn",
    "name": "Guaraní"
  },
  {
    "code": "gu",
    "name": "Gujarati"
  },
  {
    "code": "ht",
    "name": "Haitian; Haitian Creole"
  },
  {
    "code": "ha",
    "name": "Hausa"
  },
  {
    "code": "he",
    "name": "Hebrew (modern)"
  },
  {
    "code": "hz",
    "name": "Herero"
  },
  {
    "code": "hi",
    "name": "Hindi"
  },
  {
    "code": "ho",
    "name": "Hiri Motu"
  },
  {
    "code": "hu",
    "name": "Hungarian"
  },
  {
    "code": "ia",
    "name": "Interlingua"
  },
  {
    "code": "id",
    "name": "Indonesian"
  },
  {
    "code": "ie",
    "name": "Interlingue"
  },
  {
    "code": "ga",
    "name": "Irish"
  },
  {
    "code": "ig",
    "name": "Igbo"
  },
  {
    "code": "ik",
    "name": "Inupiaq"
  },
  {
    "code": "io",
    "name": "Ido"
  },
  {
    "code": "is",
    "name": "Icelandic"
  },
  {
    "code": "it",
    "name": "Italian"
  },
  {
    "code": "iu",
    "name": "Inuktitut"
  },
  {
    "code": "ja",
    "name": "Japanese"
  },
  {
    "code": "jv",
    "name": "Javanese"
  },
  {
    "code": "kl",
    "name": "Kalaallisut, Greenlandic"
  },
  {
    "code": "kn",
    "name": "Kannada"
  },
  {
    "code": "kr",
    "name": "Kanuri"
  },
  {
    "code": "ks",
    "name": "Kashmiri"
  },
  {
    "code": "kk",
    "name": "Kazakh"
  },
  {
    "code": "km",
    "name": "Khmer"
  },
  {
    "code": "ki",
    "name": "Kikuyu, Gikuyu"
  },
  {
    "code": "rw",
    "name": "Kinyarwanda"
  },
  {
    "code": "ky",
    "name": "Kyrgyz"
  },
  {
    "code": "kv",
    "name": "Komi"
  },
  {
    "code": "kg",
    "name": "Kongo"
  },
  {
    "code": "ko",
    "name": "Korean"
  },
  {
    "code": "ku",
    "name": "Kurdish"
  },
  {
    "code": "kj",
    "name": "Kwanyama, Kuanyama"
  },
  {
    "code": "la",
    "name": "Latin"
  },
  {
    "code": "lb",
    "name": "Luxembourgish, Letzeburgesch"
  },
  {
    "code": "lg",
    "name": "Ganda"
  },
  {
    "code": "li",
    "name": "Limburgish, Limburgan, Limburger"
  },
  {
    "code": "ln",
    "name": "Lingala"
  },
  {
    "code": "lo",
    "name": "Lao"
  },
  {
    "code": "lt",
    "name": "Lithuanian"
  },
  {
    "code": "lu",
    "name": "Luba-Katanga"
  },
  {
    "code": "lv",
    "name": "Latvian"
  },
  {
    "code": "gv",
    "name": "Manx"
  },
  {
    "code": "mk",
    "name": "Macedonian"
  },
  {
    "code": "mg",
    "name": "Malagasy"
  },
  {
    "code": "ms",
    "name": "Malay"
  },
  {
    "code": "ml",
    "name": "Malayalam"
  },
  {
    "code": "mt",
    "name": "Maltese"
  },
  {
    "code": "mi",
    "name": "MÄori"
  },
  {
    "code": "mr",
    "name": "Marathi (MarÄá¹­hÄ«)"
  },
  {
    "code": "mh",
    "name": "Marshallese"
  },
  {
    "code": "mn",
    "name": "Mongolian"
  },
  {
    "code": "na",
    "name": "Nauru"
  },
  {
    "code": "nv",
    "name": "Navajo, Navaho"
  },
  {
    "code": "nb",
    "name": "Norwegian Bokmål"
  },
  {
    "code": "nd",
    "name": "North Ndebele"
  },
  {
    "code": "ne",
    "name": "Nepali"
  },
  {
    "code": "ng",
    "name": "Ndonga"
  },
  {
    "code": "nn",
    "name": "Norwegian Nynorsk"
  },
  {
    "code": "no",
    "name": "Norwegian"
  },
  {
    "code": "ii",
    "name": "Nuosu"
  },
  {
    "code": "nr",
    "name": "South Ndebele"
  },
  {
    "code": "oc",
    "name": "Occitan"
  },
  {
    "code": "oj",
    "name": "Ojibwe, Ojibwa"
  },
  {
    "code": "cu",
    "name": "Old Church Slavonic, Church Slavic, Church Slavonic, Old Bulgarian, Old Slavonic"
  },
  {
    "code": "om",
    "name": "Oromo"
  },
  {
    "code": "or",
    "name": "Oriya"
  },
  {
    "code": "os",
    "name": "Ossetian, Ossetic"
  },
  {
    "code": "pa",
    "name": "Panjabi, Punjabi"
  },
  {
    "code": "pi",
    "name": "PÄli"
  },
  {
    "code": "fa",
    "name": "Persian (Farsi)"
  },
  {
    "code": "pl",
    "name": "Polish"
  },
  {
    "code": "ps",
    "name": "Pashto, Pushto"
  },
  {
    "code": "pt",
    "name": "Portuguese"
  },
  {
    "code": "qu",
    "name": "Quechua"
  },
  {
    "code": "rm",
    "name": "Romansh"
  },
  {
    "code": "rn",
    "name": "Kirundi"
  },
  {
    "code": "ro",
    "name": "Romanian, [])"
  },
  {
    "code": "ru",
    "name": "Russian"
  },
  {
    "code": "sa",
    "name": "Sanskrit (Saá¹ská¹›ta)"
  },
  {
    "code": "sc",
    "name": "Sardinian"
  },
  {
    "code": "sd",
    "name": "Sindhi"
  },
  {
    "code": "se",
    "name": "Northern Sami"
  },
  {
    "code": "sm",
    "name": "Samoan"
  },
  {
    "code": "sg",
    "name": "Sango"
  },
  {
    "code": "sr",
    "name": "Serbian"
  },
  {
    "code": "gd",
    "name": "Scottish Gaelic; Gaelic"
  },
  {
    "code": "sn",
    "name": "Shona"
  },
  {
    "code": "si",
    "name": "Sinhala, Sinhalese"
  },
  {
    "code": "sk",
    "name": "Slovak"
  },
  {
    "code": "sl",
    "name": "Slovene"
  },
  {
    "code": "so",
    "name": "Somali"
  },
  {
    "code": "st",
    "name": "Southern Sotho"
  },
  {
    "code": "es",
    "name": "Spanish; Castilian"
  },
  {
    "code": "su",
    "name": "Sundanese"
  },
  {
    "code": "sw",
    "name": "Swahili"
  },
  {
    "code": "ss",
    "name": "Swati"
  },
  {
    "code": "sv",
    "name": "Swedish"
  },
  {
    "code": "ta",
    "name": "Tamil"
  },
  {
    "code": "te",
    "name": "Telugu"
  },
  {
    "code": "tg",
    "name": "Tajik"
  },
  {
    "code": "th",
    "name": "Thai"
  },
  {
    "code": "ti",
    "name": "Tigrinya"
  },
  {
    "code": "bo",
    "name": "Tibetan Standard, Tibetan, Central"
  },
  {
    "code": "tk",
    "name": "Turkmen"
  },
  {
    "code": "tl",
    "name": "Tagalog"
  },
  {
    "code": "tn",
    "name": "Tswana"
  },
  {
    "code": "to",
    "name": "Tonga (Tonga Islands)"
  },
  {
    "code": "tr",
    "name": "Turkish"
  },
  {
    "code": "ts",
    "name": "Tsonga"
  },
  {
    "code": "tt",
    "name": "Tatar"
  },
  {
    "code": "tw",
    "name": "Twi"
  },
  {
    "code": "ty",
    "name": "Tahitian"
  },
  {
    "code": "ug",
    "name": "Uyghur, Uighur"
  },
  {
    "code": "uk",
    "name": "Ukrainian"
  },
  {
    "code": "ur",
    "name": "Urdu"
  },
  {
    "code": "uz",
    "name": "Uzbek"
  },
  {
    "code": "ve",
    "name": "Venda"
  },
  {
    "code": "vi",
    "name": "Vietnamese"
  },
  {
    "code": "vo",
    "name": "Volapük"
  },
  {
    "code": "wa",
    "name": "Walloon"
  },
  {
    "code": "cy",
    "name": "Welsh"
  },
  {
    "code": "wo",
    "name": "Wolof"
  },
  {
    "code": "fy",
    "name": "Western Frisian"
  },
  {
    "code": "xh",
    "name": "Xhosa"
  },
  {
    "code": "yi",
    "name": "Yiddish"
  },
  {
    "code": "yo",
    "name": "Yoruba"
  },
  {
    "code": "za",
    "name": "Zhuang, Chuang"
  },
  {
    "code": "zu",
    "name": "Zulu"
  }
]

मुझे इन भाषा के साथ दिनांक-प्रारूप चाहिए। मुझे बताएं कि क्या आप मदद कर सकते हैं
अंकुर अकवलिया

अब जब मैं पूरी तरह से जाँच में गया था - "az" कोड का दोहराव है जो ISO639-1 मानक द्वारा नहीं है। संग्रह 184 आइटम होना चाहिए और "एज़" केवल एक बार मौजूद होना चाहिए।
क्रिश बोन

3

यह PHP फ़ंक्शन लाइब्रेरी ऑफ़ कांग्रेस डेटा फ़ाइल का उपयोग करके भाषा कोड को भाषा के नाम में बदल देगा:

function lang_code_to_name($code)
{
    // init
    $lines = array();
    $line_items = array();
    $language = '';
    $code = strtolower($code);

    // strip any possible sub-language
    $pos = strpos($code, '-');
    if ($pos) {$code = substr($code, 0, $pos);}

    // get code list from Library of Congress
    // format: five elements per line
    // ISO 639-2 Alpha-3 bibliographic code|ISO 639-2 Alpha-3 terminology code|ISO 639-1 Alpha-2 code|English language name(s)|French language name(s)
    $url = 'http://loc.gov/standards/iso639-2/ISO-639-2_utf-8.txt';
    $list = file_get_contents($url);

    if (!$list) {return $language;}

    // read the file
    $lines = explode("\n", $list);
    for ($i; $i < sizeof($lines); $i++)
    {
        $line_item = explode("|", $lines[$i]);
        if (($line_item[0] == $code) || ($line_item[1] == $code) || ($line_item[2] == $code))
        {
            $language = $line_item[3];
            break;
        }
    }

    // exit
    return $language;
}

2

यह छोटा कोड एक सरणी बनाने में मदद कर सकता है, 2 कुंजी कोड "iso639-1" को 'कुंजी' और भाषा का नाम 'मान' के रूप में डेटा प्राप्त कर रहा है: http://loc.gov/standards/iso639 से -2 / आईएसओ 639-2_utf-8.txt

<?php
$lang = array();
$row = 1;
if (($handle = fopen('http://loc.gov/standards/iso639-2/ISO-639-2_utf-8.txt', 'r')) !== FALSE) {
  while (($data = fgetcsv($handle, 1000, '|')) !== FALSE) {
    $row++;
    if (!empty($data[2])) {
      /* to get only the first language (anything before ;) */
      $lang[$data[2]]  = strtok($data[3], ';'); 
     }
  }
  fclose($handle);
}

?>

1

मैंने 'Instine' उत्तर को C # प्रारूप में बदल दिया है

public class Language
{
	public string Code;
	public string Name;
	public string NativeName;

	public Language(string code, string name, string nativeName)
	{
		Code = code;
		Name = name;
		NativeName = nativeName;
	}

	public Language()
	{
	}
}

public class Languages
{
	public IList<Language> LanguagesList = new List<Language>();

	protected void AddLang(string code, string name, string nativeName)
	{
		var lang = new Language(code, name, nativeName);
		LanguagesList.Add(lang);
	}

	public void Initialize()
	{
		AddLang("ab", "Abkhaz", "аҧсуа");

		AddLang(
			"aa",
			"Afar",
			"Afaraf"
			);
		AddLang(
			"af",
			"Afrikaans",
			"Afrikaans"
			);
		AddLang(
			"ak",
			"Akan",
			"Akan"
			);
		AddLang(
			"sq",
			"Albanian",
			"Shqip"
			);
		AddLang(
			"am",
			"Amharic",
			"አማርኛ"
			);
		AddLang(
			"ar",
			"Arabic",
			"العربية"
			);
		AddLang(
			"an",
			"Aragonese",
			"Aragonés"
			);
		AddLang(
			"hy",
			"Armenian",
			"Հայերեն"
			);
		AddLang(
			"as",
			"Assamese",
			"অসমীয়া"
			);
		AddLang(
			"av",
			"Avaric",
			"авар мацӀ, магӀарул мацӀ"
			);
		AddLang(
			"ae",
			"Avestan",
			"avesta"
			);
		AddLang(
			"ay",
			"Aymara",
			"aymar aru"
			);
		AddLang(
			"az",
			"Azerbaijani",
			"azərbaycan dili"
			);
		AddLang(
			"bm",
			"Bambara",
			"bamanankan"
			);
		AddLang(
			"ba",
			"Bashkir",
			"башҡорт теле"
			);
		AddLang(
			"eu",
			"Basque",
			"euskara, euskera"
			);
		AddLang(
			"be",
			"Belarusian",
			"Беларуская"
			);
		AddLang(
			"bn",
			"Bengali",
			"বাংলা"
			);
		AddLang(
			"bh",
			"Bihari",
			"भोजपुरी"
			);
		AddLang(
			"bi",
			"Bislama",
			"Bislama"
			);
		AddLang(
			"bs",
			"Bosnian",
			"bosanski jezik"
			);
		AddLang(
			"br",
			"Breton",
			"brezhoneg"
			);
		AddLang(
			"bg",
			"Bulgarian",
			"български език"
			);
		AddLang(
			"my",
			"Burmese",
			"ဗမာစာ"
			);
		AddLang(
			"ca",
			"Catalan; Valencian",
			"Català"
			);
		AddLang(
			"ch",
			"Chamorro",
			"Chamoru"
			);
		AddLang(
			"ce",
			"Chechen",
			"нохчийн мотт"
			);
		AddLang(
			"ny",
			"Chichewa; Chewa; Nyanja",
			"chiCheŵa, chinyanja"
			);
		AddLang(
			"zh",
			"Chinese",
			"中文 (Zhōngwén), 汉语, 漢語"
			);
		AddLang(
			"cv",
			"Chuvash",
			"чӑваш чӗлхи"
			);
		AddLang(
			"kw",
			"Cornish",
			"Kernewek"
			);
		AddLang(
			"co",
			"Corsican",
			"corsu, lingua corsa"
			);
		AddLang(
			"cr",
			"Cree",
			"ᓀᐦᐃᔭᐍᐏᐣ"
			);
		AddLang(
			"hr",
			"Croatian",
			"hrvatski"
			);
		AddLang(
			"cs",
			"Czech",
			"česky, čeština"
			);
		AddLang(
			"da",
			"Danish",
			"dansk"
			);
		AddLang(
			"dv",
			"Divehi; Dhivehi; Maldivian;",
			"ދިވެހި"
			);
		AddLang(
			"nl",
			"Dutch",
			"Nederlands, Vlaams"
			);
		AddLang(
			"en",
			"English",
			"English"
			);
		AddLang(
			"eo",
			"Esperanto",
			"Esperanto"
			);
		AddLang(
			"et",
			"Estonian",
			"eesti, eesti keel"
			);
		AddLang(
			"ee",
			"Ewe",
			"Eʋegbe"
			);
		AddLang(
			"fo",
			"Faroese",
			"føroyskt"
			);
		AddLang(
			"fj",
			"Fijian",
			"vosa Vakaviti"
			);
		AddLang(
			"fi",
			"Finnish",
			"suomi, suomen kieli"
			);
		AddLang(
			"fr",
			"French",
			"français, langue française"
			);
		AddLang(
			"ff",
			"Fula; Fulah; Pulaar; Pular",
			"Fulfulde, Pulaar, Pular"
			);
		AddLang(
			"gl",
			"Galician",
			"Galego"
			);
		AddLang(
			"ka",
			"Georgian",
			"ქართული"
			);
		AddLang(
			"de",
			"German",
			"Deutsch"
			);
		AddLang(
			"el",
			"Greek, Modern",
			"Ελληνικά"
			);
		AddLang(
			"gn",
			"Guaraní",
			"Avañeẽ"
			);
		AddLang(
			"gu",
			"Gujarati",
			"ગુજરાતી"
			);
		AddLang(
			"ht",
			"Haitian; Haitian Creole",
			"Kreyòl ayisyen"
			);
		AddLang(
			"ha",
			"Hausa",
			"Hausa, هَوُسَ"
			);
		AddLang(
			"he",
			"Hebrew (modern)",
			"עברית"
			);
		AddLang(
			"hz",
			"Herero",
			"Otjiherero"
			);
		AddLang(
			"hi",
			"Hindi",
			"हिन्दी, हिंदी"
			);
		AddLang(
			"ho",
			"Hiri Motu",
			"Hiri Motu"
			);
		AddLang(
			"hu",
			"Hungarian",
			"Magyar"
			);
		AddLang(
			"ia",
			"Interlingua",
			"Interlingua"
			);
		AddLang(
			"id",
			"Indonesian",
			"Bahasa Indonesia"
			);
		AddLang(
			"ie",
			"Interlingue",
			"Originally called Occidental; then Interlingue after WWII"
			);
		AddLang(
			"ga",
			"Irish",
			"Gaeilge"
			);
		AddLang(
			"ig",
			"Igbo",
			"Asụsụ Igbo"
			);
		AddLang(
			"ik",
			"Inupiaq",
			"Iñupiaq, Iñupiatun"
			);
		AddLang(
			"io",
			"Ido",
			"Ido"
			);
		AddLang(
			"is",
			"Icelandic",
			"Íslenska"
			);
		AddLang(
			"it",
			"Italian",
			"Italiano"
			);
		AddLang(
			"iu",
			"Inuktitut",
			"ᐃᓄᒃᑎᑐᑦ"
			);
		AddLang(
			"ja",
			"Japanese",
			"日本語 (にほんご/にっぽんご)"
			);
		AddLang(
			"jv",
			"Javanese",
			"basa Jawa"
			);
		AddLang(
			"kl",
			"Kalaallisut, Greenlandic",
			"kalaallisut, kalaallit oqaasii"
			);
		AddLang(
			"kn",
			"Kannada",
			"ಕನ್ನಡ"
			);
		AddLang(
			"kr",
			"Kanuri",
			"Kanuri"
			);
		AddLang(
			"ks",
			"Kashmiri",
			"कश्मीरी, كشميري‎"
			);
		AddLang(
			"kk",
			"Kazakh",
			"Қазақ тілі"
			);
		AddLang(
			"km",
			"Khmer",
			"ភាសាខ្មែរ"
			);
		AddLang(
			"ki",
			"Kikuyu, Gikuyu",
			"Gĩkũyũ"
			);
		AddLang(
			"rw",
			"Kinyarwanda",
			"Ikinyarwanda"
			);
		AddLang(
			"ky",
			"Kirghiz, Kyrgyz",
			"кыргыз тили"
			);
		AddLang(
			"kv",
			"Komi",
			"коми кыв"
			);
		AddLang(
			"kg",
			"Kongo",
			"KiKongo"
			);
		AddLang(
			"ko",
			"Korean",
			"한국어 (韓國語), 조선말 (朝鮮語)"
			);
		AddLang(
			"ku",
			"Kurdish",
			"Kurdî, كوردی‎"
			);
		AddLang(
			"kj",
			"Kwanyama, Kuanyama",
			"Kuanyama"
			);
		AddLang(
			"la",
			"Latin",
			"latine, lingua latina"
			);
		AddLang(
			"lb",
			"Luxembourgish, Letzeburgesch",
			"Lëtzebuergesch"
			);
		AddLang(
			"lg",
			"Luganda",
			"Luganda"
			);
		AddLang(
			"li",
			"Limburgish, Limburgan, Limburger",
			"Limburgs"
			);
		AddLang(
			"ln",
			"Lingala",
			"Lingála"
			);
		AddLang(
			"lo",
			"Lao",
			"ພາສາລາວ"
			);
		AddLang(
			"lt",
			"Lithuanian",
			"lietuvių kalba"
			);
		AddLang(
			"lu",
			"Luba-Katanga",
			""
			);
		AddLang(
			"lv",
			"Latvian",
			"latviešu valoda"
			);
		AddLang(
			"gv",
			"Manx",
			"Gaelg, Gailck"
			);
		AddLang(
			"mk",
			"Macedonian",
			"македонски јазик"
			);
		AddLang(
			"mg",
			"Malagasy",
			"Malagasy fiteny"
			);
		AddLang(
			"ms",
			"Malay",
			"bahasa Melayu, بهاس ملايو‎"
			);
		AddLang(
			"ml",
			"Malayalam",
			"മലയാളം"
			);
		AddLang(
			"mt",
			"Maltese",
			"Malti"
			);
		AddLang(
			"mi",
			"Māori",
			"te reo Māori"
			);
		AddLang(
			"mr",
			"Marathi (Marāṭhī)",
			"मराठी"
			);
		AddLang(
			"mh",
			"Marshallese",
			"Kajin M̧ajeļ"
			);
		AddLang(
			"mn",
			"Mongolian",
			"монгол"
			);
		AddLang(
			"na",
			"Nauru",
			"Ekakairũ Naoero"
			);
		AddLang(
			"nv",
			"Navajo, Navaho",
			"Diné bizaad, Dinékʼehǰí"
			);
		AddLang(
			"nb",
			"Norwegian Bokmål",
			"Norsk bokmål"
			);
		AddLang(
			"nd",
			"North Ndebele",
			"isiNdebele"
			);
		AddLang(
			"ne",
			"Nepali",
			"नेपाली"
			);
		AddLang(
			"ng",
			"Ndonga",
			"Owambo"
			);
		AddLang(
			"nn",
			"Norwegian Nynorsk",
			"Norsk nynorsk"
			);
		AddLang(
			"no",
			"Norwegian",
			"Norsk"
			);
		AddLang(
			"ii",
			"Nuosu",
			"ꆈꌠ꒿ Nuosuhxop"
			);
		AddLang(
			"nr",
			"South Ndebele",
			"isiNdebele"
			);
		AddLang(
			"oc",
			"Occitan",
			"Occitan"
			);
		AddLang(
			"oj",
			"Ojibwe, Ojibwa",
			"ᐊᓂᔑᓈᐯᒧᐎᓐ"
			);
		AddLang(
			"cu",
			"Old Church Slavonic, Church Slavic, Church Slavonic, Old Bulgarian, Old Slavonic",
			"ѩзыкъ словѣньскъ"
			);
		AddLang(
			"om",
			"Oromo",
			"Afaan Oromoo"
			);
		AddLang(
			"or",
			"Oriya",
			"ଓଡ଼ିଆ"
			);
		AddLang(
			"os",
			"Ossetian, Ossetic",
			"ирон æвзаг"
			);
		AddLang(
			"pa",
			"Panjabi, Punjabi",
			"ਪੰਜਾਬੀ, پنجابی‎"
			);
		AddLang(
			"pi",
			"Pāli",
			"पाऴि"
			);
		AddLang(
			"fa",
			"Persian",
			"فارسی"
			);
		AddLang(
			"pl",
			"Polish",
			"Polski"
			);
		AddLang(
			"ps",
			"Pashto, Pushto",
			"پښتو"
			);
		AddLang(
			"pt",
			"Portuguese",
			"Português"
			);
		AddLang(
			"qu",
			"Quechua",
			"Runa Simi, Kichwa"
			);
		AddLang(
			"rm",
			"Romansh",
			"rumantsch grischun"
			);
		AddLang(
			"rn",
			"Kirundi",
			"kiRundi"
			);
		AddLang(
			"ro",
			"Romanian, Moldavian, Moldovan",
			"română"
			);
		AddLang(
			"ru",
			"Russian",
			"русский язык"
			);
		AddLang(
			"sa",
			"Sanskrit (Saṁskṛta)",
			"संस्कृतम्"
			);
		AddLang(
			"sc",
			"Sardinian",
			"sardu"
			);
		AddLang(
			"sd",
			"Sindhi",
			"सिन्धी, سنڌي، سندھی‎"
			);
		AddLang(
			"se",
			"Northern Sami",
			"Davvisámegiella"
			);
		AddLang(
			"sm",
			"Samoan",
			"gagana faa Samoa"
			);
		AddLang(
			"sg",
			"Sango",
			"yângâ tî sängö"
			);
		AddLang(
			"sr",
			"Serbian",
			"српски језик"
			);
		AddLang(
			"gd",
			"Scottish Gaelic; Gaelic",
			"Gàidhlig"
			);
		AddLang(
			"sn",
			"Shona",
			"chiShona"
			);
		AddLang(
			"si",
			"Sinhala, Sinhalese",
			"සිංහල"
			);
		AddLang(
			"sk",
			"Slovak",
			"slovenčina"
			);
		AddLang(
			"sl",
			"Slovene",
			"slovenščina"
			);
		AddLang(
			"so",
			"Somali",
			"Soomaaliga, af Soomaali"
			);
		AddLang(
			"st",
			"Southern Sotho",
			"Sesotho"
			);
		AddLang(
			"es",
			"Spanish; Castilian",
			"español, castellano"
			);
		AddLang(
			"su",
			"Sundanese",
			"Basa Sunda"
			);
		AddLang(
			"sw",
			"Swahili",
			"Kiswahili"
			);
		AddLang(
			"ss",
			"Swati",
			"SiSwati"
			);
		AddLang(
			"sv",
			"Swedish",
			"svenska"
			);
		AddLang(
			"ta",
			"Tamil",
			"தமிழ்"
			);
		AddLang(
			"te",
			"Telugu",
			"తెలుగు"
			);
		AddLang(
			"tg",
			"Tajik",
			"тоҷикӣ, toğikī, تاجیکی‎"
			);
		AddLang(
			"th",
			"Thai",
			"ไทย"
			);
		AddLang(
			"ti",
			"Tigrinya",
			"ትግርኛ"
			);
		AddLang(
			"bo",
			"Tibetan Standard, Tibetan, Central",
			"བོད་ཡིག"
			);
		AddLang(
			"tk",
			"Turkmen",
			"Türkmen, Түркмен"
			);
		AddLang(
			"tl",
			"Tagalog",
			"Wikang Tagalog, ᜏᜒᜃᜅ᜔ ᜆᜄᜎᜓᜄ᜔"
			);
		AddLang(
			"tn",
			"Tswana",
			"Setswana"
			);
		AddLang(
			"to",
			"Tonga (Tonga Islands)",
			"faka Tonga"
			);
		AddLang(
			"tr",
			"Turkish",
			"Türkçe"
			);
		AddLang(
			"ts",
			"Tsonga",
			"Xitsonga"
			);
		AddLang(
			"tt",
			"Tatar",
			"татарча, tatarça, تاتارچا‎"
			);
		AddLang(
			"tw",
			"Twi",
			"Twi"
			);
		AddLang(
			"ty",
			"Tahitian",
			"Reo Tahiti"
			);
		AddLang(
			"ug",
			"Uighur, Uyghur",
			"Uyƣurqə, ئۇيغۇرچە‎"
			);
		AddLang(
			"uk",
			"Ukrainian",
			"українська"
			);
		AddLang(
			"ur",
			"Urdu",
			"اردو"
			);
		AddLang(
			"uz",
			"Uzbek",
			"zbek, Ўзбек, أۇزبېك‎"
			);
		AddLang(
			"ve",
			"Venda",
			"Tshivenḓa"
			);
		AddLang(
			"vi",
			"Vietnamese",
			"Tiếng Việt"
			);
		AddLang(
			"vo",
			"Volapük",
			"Volapük"
			);
		AddLang(
			"wa",
			"Walloon",
			"Walon"
			);
		AddLang(
			"cy",
			"Welsh",
			"Cymraeg"
			);
		AddLang(
			"wo",
			"Wolof",
			"Wollof"
			);
		AddLang(
			"fy",
			"Western Frisian",
			"Frysk"
			);
		AddLang(
			"xh",
			"Xhosa",
			"isiXhosa"
			);
		AddLang(
			"yi",
			"Yiddish",
			"ייִדיש"
			);
		AddLang(
			"yo",
			"Yoruba",
			"Yorùbá"
			);
		AddLang(
			"za",
			"Zhuang, Chuang",
			"Saɯ cueŋƅ, Saw cuengh");
	}
}

हमारी साइट का प्रयोग करके, आप स्वीकार करते हैं कि आपने हमारी Cookie Policy और निजता नीति को पढ़ और समझा लिया है।
Licensed under cc by-sa 3.0 with attribution required.