In Java, you can call Locale.getAvailableLocales() to get the list of available locales.
I was expecting an equivalent from the PHP Locale class, but co
On Windows you can try to call the setlocale() php function with all the items of the following list:
http://msdn.microsoft.com/en-us/goglobal/bb895996.aspx
Here is a code sniplet to list all available locales on a Windows based host:
'."\n";
echo ''."\n";
echo ' Languange '."\n";
echo ' Sub-Languange '."\n";
echo ' Languange String '."\n";
echo ' '."\n";
foreach ( $langs as $lang ) {
echo ''."\n";
echo ' '.$lang[0].' '."\n";
echo ' '.$lang[1].' '."\n";
$a = array();
foreach ( $lang[2] as $lang_code ) {
$loc = setlocale( LC_ALL, $lang_code );
$a []= $lang_code.' '.( false === $loc ? '✖' : '✔ - '.$loc );
}
echo ' '.implode( '
', $a ).' '."\n";
echo ' '."\n";
}
echo ''."\n";
// Note: Norvegian (Bokmal) is Norvegian (Bokmål), see: http://en.wikipedia.org/wiki/Bokmål
?>