HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.

setlocale and php 5.6

I am trying to run this script on the server in which php 5.6 is enabled and it gives me a die...

/* Set locale to Dutch */
date_default_timezone_set("Europe/Amsterdam");
setlocale(LC_ALL, 'nl_NL') or die('no dutch');

this also dies:
setlocale(LC_ALL, 'nl_NL.utf8') or die('no dutch');
and this also:
setlocale(LC_ALL, '[email protected]') or die('no dutch');

Even other languages; they all die

    setlocale(LC_ALL, 'de_DE') or die('no german'); 
    setlocale(LC_ALL, 'de_DE.utf8') or die('no german utf8');
    setlocale(LC_ALL, '[email protected]') or die('no german @euro');

    setlocale(LC_ALL, 'fr_FR') or die('no french');
    setlocale(LC_ALL, 'fr_FR.utf8') or die('no french utf8');
    setlocale(LC_ALL, '[email protected]') or die('no french @euro');

This problem is only at version 5.6 .
Version 5.5 works everything fine

Is this problem due to 5.6 version or are the locales not installed on the server?

Tagged:

Comments

Sign In or Register to comment.