Bug #66265 [NEW]: gettext is not working anymore

From: Date: Wed, 11 Dec 2013 16:42:19 +0000
Subject: Bug #66265 [NEW]: gettext is not working anymore
Groups: php.bugs 
Request: Send a blank email to php-bugs+get-183236@lists.php.net to get a copy of this message
From:             roeycohen at gmail dot com
Operating system: windows
PHP version:      5.5.6
Package:          Gettext related
Bug Type:         Bug
Bug description:gettext is not working anymore

Description:
------------
as simple as that, a code that used to work perfect now doesn't.
switching back to version 5.4.8 solves the problem.

i've made sure that in the php.ini the gettext extension is on
and also tried turning off OPCache, but it didn't help.
as a matter of fact, i've compared both php.ini to make sure that most
options are the same.

Test script:
---------------
$domain = 'domain';

putenv("LC_ALL=en_US");
setlocale(LC_ALL, 'en_US');

$path = realpath('./locale');
bindtextdomain($domain, $path);
bind_textdomain_codeset($domain, "UTF-8");
textdomain($domain);

echo _('hello');

Expected result:
----------------
the text hello will be replaced with the string within the mo file.

Actual result:
--------------
the original string is returned.

-- 
Edit bug report at https://bugs.php.net/bug.php?id=66265&edit=1
-- 
Try a snapshot (PHP 5.4):   https://bugs.php.net/fix.php?id=66265&r=trysnapshot54
Try a snapshot (PHP 5.5):   https://bugs.php.net/fix.php?id=66265&r=trysnapshot55
Try a snapshot (trunk):     https://bugs.php.net/fix.php?id=66265&r=trysnapshottrunk
Fixed in SVN:               https://bugs.php.net/fix.php?id=66265&r=fixed
Fixed in release:           https://bugs.php.net/fix.php?id=66265&r=alreadyfixed
Need backtrace:             https://bugs.php.net/fix.php?id=66265&r=needtrace
Need Reproduce Script:      https://bugs.php.net/fix.php?id=66265&r=needscript
Try newer version:          https://bugs.php.net/fix.php?id=66265&r=oldversion
Not developer issue:        https://bugs.php.net/fix.php?id=66265&r=support
Expected behavior:          https://bugs.php.net/fix.php?id=66265&r=notwrong
Not enough info:            https://bugs.php.net/fix.php?id=66265&r=notenoughinfo
Submitted twice:            https://bugs.php.net/fix.php?id=66265&r=submittedtwice
register_globals:           https://bugs.php.net/fix.php?id=66265&r=globals
PHP 4 support discontinued: https://bugs.php.net/fix.php?id=66265&r=php4
Daylight Savings:           https://bugs.php.net/fix.php?id=66265&r=dst
IIS Stability:              https://bugs.php.net/fix.php?id=66265&r=isapi
Install GNU Sed:            https://bugs.php.net/fix.php?id=66265&r=gnused
Floating point limitations: https://bugs.php.net/fix.php?id=66265&r=float
No Zend Extensions:         https://bugs.php.net/fix.php?id=66265&r=nozend
MySQL Configuration Error:  https://bugs.php.net/fix.php?id=66265&r=mysqlcfg



Thread (33 messages)

« previous php.bugs (#183236) next »