{"id":15984917,"url":"https://github.com/divineomega/php-languages","last_synced_at":"2026-02-09T02:04:55.549Z","repository":{"id":56969686,"uuid":"137684248","full_name":"DivineOmega/php-languages","owner":"DivineOmega","description":"A tiny package to help convert between languages names (such as English, French, German) and various ISO language codes (such as en, fr, de).","archived":false,"fork":false,"pushed_at":"2018-12-08T23:08:26.000Z","size":12,"stargazers_count":2,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-07-29T07:47:57.212Z","etag":null,"topics":["iso639","iso639-1","iso639-2","iso639-3","language","languages","php","php-library"],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"lgpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/DivineOmega.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-06-17T20:18:53.000Z","updated_at":"2019-05-21T07:37:23.000Z","dependencies_parsed_at":"2022-08-21T10:50:38.404Z","dependency_job_id":null,"html_url":"https://github.com/DivineOmega/php-languages","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/DivineOmega/php-languages","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DivineOmega%2Fphp-languages","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DivineOmega%2Fphp-languages/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DivineOmega%2Fphp-languages/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DivineOmega%2Fphp-languages/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/DivineOmega","download_url":"https://codeload.github.com/DivineOmega/php-languages/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DivineOmega%2Fphp-languages/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29254306,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-09T01:52:29.835Z","status":"online","status_checked_at":"2026-02-09T02:00:09.501Z","response_time":56,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["iso639","iso639-1","iso639-2","iso639-3","language","languages","php","php-library"],"created_at":"2024-10-08T02:11:21.142Z","updated_at":"2026-02-09T02:04:55.535Z","avatar_url":"https://github.com/DivineOmega.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# PHP Languages\n\nPHP Languages is a tiny package to help convert between languages names (such as English, French, German) and various ISO language codes (such as en, fr, de).\n\n## Installation\n\nTo install PHP Languages, just run the following Composer command.\n\n```bash\ncomposer require divineomega/php-languages\n```\n\n## Usage\n\nFirst, you need to get a `Language` object. You can get object by\nlanguage name or ISO code. You can also find all languages that belong\nto a particular family.\n\n```php\nuse \\DivineOmega\\Languages\\Language;\n\n$language = Language::getByName('German');\n$language = Language::getByNativeName('Deutsch');\n$language = Language::getByIso639_1('de');\n$language = Language::getByIso639_2_t('deu');\n$language = Language::getByIso639_2_b('ger');\n$language = Language::getByIso639_3('deu');\n$languages = Language::getByFamily('Indo-European');\n```\n\nOnce you have your `Language` object, you can access its various public \nproperties to yield information about the language.\n\n```php\necho $language-\u003efamily;         // German\necho $language-\u003ename;           // Deutsch\necho $language-\u003enativeName;     // de\necho $language-\u003eiso639_1;       // deu\necho $language-\u003eiso639_2_t;     // ger\necho $language-\u003eiso639_2_b;     // deu\necho $language-\u003eiso639_3;       // Indo-European\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdivineomega%2Fphp-languages","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdivineomega%2Fphp-languages","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdivineomega%2Fphp-languages/lists"}