countrytext / extracting-country-from-text
Applications that extract country names from strings
Installs: 6
Dependents: 0
Suggesters: 0
Security: 0
Stars: 1
Watchers: 0
Forks: 0
Open Issues: 0
pkg:composer/countrytext/extracting-country-from-text
README
Applications that extract country names from strings
Installation
After installing the composer, execute the following commands
composer require countrytext/extracting-country-from-text
Usage
$country = new ExtractCounty([ "searchWord" => "korea", // required "searcItem" => "name", // optional "fullSearch" => false, // optional "language" => "en", // optional ]); $country->getCountryFullName(); // Array ( [0] => Korea (Democratic People's Republic of) [1] => Korea, Republic of ) $country->getCountryTwoLetter(); // Array ( [0] => kp [1] => kr ) $country->getCountryThreeLetter(); // Array ( [0] => prk [1] => kor )
Reference
I made it by referring to this repository