Bug #55873 [Opn->Nab]: resourcebundle shoud throw error if it desn't recognize the file
| From: | cataphract@php.net | Date: | Thu, 24 May 2012 12:38:58 +0000 |
| Subject: | Bug #55873 [Opn->Nab]: resourcebundle shoud throw error if it desn't recognize the file | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-170778@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=55873&edit=1
ID: 55873
Updated by: cataphract@php.net
Reported by: miha dot vrhovnik at domenca dot com
Summary: resourcebundle shoud throw error if it desn't
recognize the file
-Status: Open
+Status: Not a bug
Type: Bug
Package: I18N and L10N related
Operating System: Linux
PHP Version: 5.3.8
Block user comment: N
Private report: N
New Comment:
Sorry, but your problem does not imply a bug in PHP itself. For a
list of more appropriate places to ask for help using PHP, please
visit http://www.php.net/support.php as this bug system
is not the
appropriate forum for asking support questions. Due to the volume
of reports we can not explain in detail here why your report is not
a bug. The support channels will be able to provide an explanation
for you.
Thank you for your interest in PHP.
Previous Comments:
------------------------------------------------------------------------
[2012-02-21 10:14:43] jinmoku at hotmail dot com
use the ini directive : intl.error_level
------------------------------------------------------------------------
[2011-10-08 15:45:23] miha dot vrhovnik at domenca dot com
Description:
------------
ICU 4.4 upgraded it's resource file format. If you are using older version of ICU e.g 4.2 and
try to load a newer version of resource file function returns null but there is no way of developer
knowing what the hell happened. Getting some sort of error message would be most welcome otherwise
you just get a WTF moment.
Test script:
---------------
<?php
error_reporting(E_ALL);
ini_set('display_errors', 1);
$resourceDir = __DIR__;
//2 files needed ar it seems ther Resoucebundle won't reload? the same file or something like
that another bug?
$resFile_v1 = $resourceDir . '/en1.res';
$resFile_v2 = $resourceDir . '/en2.res';
$fileData_v1 =
base64_decode('IADaJxQAAAAAAAIAUmVzQgECAAABBAAAAAAAAAAAAAALAAAgBgAAAAgAAAANAAAADQAAAAEAAAAA
AAAAZm9vAAMAAABiAGEAcgAAAAEAHAAIAAAA');
$fileData_v2 =
base64_decode('IADaJxQAAAAAAAIAUmVzQgIAAAABBAAAAAAAAAAAAAAFAABQBwAAAAkAAAANAAAADQAAAAEAAAAA
AAAADQAAAGZvbwAAAGIAYQByAAAAAQAgAAEA
');
file_put_contents($resFile_v1, $fileData_v1);
$rb = new ResourceBundle('en1', $resourceDir);
var_dump($rb);
/output object(ResourceBundle)#1 (0) {
}
*/
file_put_contents($resFile_v2, $fileData_v2);
$rb = new ResourceBundle('en2', $resourceDir);
var_dump($rb);
/output object(ResourceBundle)#1 (0) {
}
*/
//no error no warning nothing
unlink($resFile_v1);
unlink($resFile_v2);
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=55873&edit=1