PHP code example of domprojects / codeigniter4-country

1. Go to this page and download the library: Download domprojects/codeigniter4-country library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

domprojects / codeigniter4-country example snippets


helper('country');

$countries = countryList();

$name = countryIsoToName('fr');

echo countryDropdown('country', ['class' => 'form-select'], 'FR');
text
src/
  Helpers/
    country_helper.php
  Language/
    <locale>/
      Country.php