Set the locale to US English and then back to default again in PHP

Description

The following code shows how to set the locale to US English and then back to default again.

Example


  // w ww  .  j  av a2s .  c om
<?php
    echo setlocale(LC_ALL,"US");
    echo "<br>";
    echo setlocale(LC_ALL,NULL);
?>

The code above generates the following result.





















Home »
  PHP Tutorial »
    Development »




Environment
Error
Hash
Include
Locale
Math
Network
Output
Reflection
PHP Regular Expressions