Changeset 1126
- Timestamp:
- 10/17/08 18:23:19 (3 months ago)
- Files:
-
- trunk/lib/jelix/core/jBundle.class.php (modified) (5 diffs)
- trunk/lib/jelix/CREDITS (modified) (1 diff)
- trunk/testapp/modules/jelix_tests/locales/fr_FR/tests1.UTF-8.properties (modified) (1 diff)
- trunk/testapp/modules/jelix_tests/locales/fr_FR/testunit.ISO-8859-1.properties (modified) (1 diff)
- trunk/testapp/modules/jelix_tests/tests/core.jlocale.html_cli.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/lib/jelix/core/jBundle.class.php
r1124 r1126 5 5 * @author Laurent Jouanneau 6 6 * @author Gerald Croes 7 * @contributor Julien Issler, Yannick Le Guédart 7 * @contributor Julien Issler, Yannick Le Guédart, Dominique Papin 8 8 * @copyright 2001-2005 CopixTeam, 2005-2008 Laurent Jouanneau 9 9 * Some parts of this file are took from Copix Framework v2.3dev20050901, CopixI18N.class.php, http://www.copix.org. … … 11 11 * initial authors : Gerald Croes, Laurent Jouanneau. 12 12 * enhancement by Laurent Jouanneau for Jelix. 13 * @copyright 2008 Julien Issler, 2008 Yannick Le Guédart 13 * @copyright 2008 Julien Issler, 2008 Yannick Le Guédart, 2008 Dominique Papin 14 14 * @link http://www.jelix.org 15 15 * @licence GNU Lesser General Public Licence see LICENCE file or http://www.gnu.org/licenses/lgpl.html … … 110 110 111 111 if (($f = @fopen ($fichier, 'r')) !== false) { 112 $utf8Mod = ($charset=='UTF-8')?'u':''; 112 113 $multiline=false; 113 114 $linenumber=0; … … 118 119 $line=rtrim($line); 119 120 if($multiline){ 120 if(preg_match("/^\s*(.*)\s*(\\\\?)$/U" , $line, $match)){121 if(preg_match("/^\s*(.*)\s*(\\\\?)$/U".$utf8Mod, $line, $match)){ 121 122 $multiline= ($match[2] =="\\"); 122 123 if (strlen ($match[1])) { … … 129 130 throw new Exception('Syntaxe error in file properties '.$fichier.' line '.$linenumber,210); 130 131 } 131 }elseif(preg_match("/^\s*(.+)\s*=\s*(.*)\s*(\\\\?)$/U" ,$line, $match)){132 }elseif(preg_match("/^\s*(.+)\s*=\s*(.*)\s*(\\\\?)$/U".$utf8Mod,$line, $match)){ 132 133 // on a bien un cle=valeur 133 134 $key=$match[1]; trunk/lib/jelix/CREDITS
r1121 r1126 83 83 - added support of 'else' keyword for block plugin in jtpl (#349) 84 84 - added support of <reset> in jforms (#258) 85 - fixed some bugs (#362,#585,#718 )85 - fixed some bugs (#362,#585,#718,#713) 86 86 - jforms dao datasource : enhancements (#581,#582) 87 87 - added ifctrl block plugin (#601) trunk/testapp/modules/jelix_tests/locales/fr_FR/tests1.UTF-8.properties
r1124 r1126 2 2 second.locale = ceci est une phrase 2 fr_FR 3 3 multiline.locale.with.accent = Chaîne à\ 4 tester 4 tester 5 multiline.locale.with.accent2 = Chaîne à\ 6 tester à \ 7 foison trunk/testapp/modules/jelix_tests/locales/fr_FR/testunit.ISO-8859-1.properties
r1124 r1126 1 1 moduleDescription = Tests unitaires jelix 2 2 multiline.locale.with.accent = Cha� �tester 3 multiline.locale.with.accent2 = Cha� � tester � 4 foison trunk/testapp/modules/jelix_tests/tests/core.jlocale.html_cli.php
r1124 r1126 4 4 * @subpackage jelix_tests module 5 5 * @author Jouanneau Laurent 6 * @contributor Julien Issler 6 * @contributor Julien Issler, Dominique Papin 7 7 * @copyright 2006-2007 Jouanneau laurent 8 * @copyright 2008 Julien Issler 8 * @copyright 2008 Julien Issler, 2008 Dominique Papin 9 9 * @link http://www.jelix.org 10 10 * @licence GNU Lesser General Public Licence see LICENCE file or http://www.gnu.org/licenses/lgpl.html … … 80 80 $this->assertEqual('ceci est une phrase fr_FR',jLocale::get('tests1.first.locale', null, 'fr_FR')); 81 81 $this->assertEqualOrDiff('Chaîne à tester',jLocale::get('tests1.multiline.locale.with.accent')); 82 $this->assertEqualOrDiff('Chaîne à tester à foison',jLocale::get('tests1.multiline.locale.with.accent2')); 82 83 $this->assertEqualOrDiff(utf8_decode('Chaîne à tester'),jLocale::get('testunit.multiline.locale.with.accent',null,null,'ISO-8859-1')); 84 $this->assertEqualOrDiff(utf8_decode('Chaîne à tester à foison'),jLocale::get('testunit.multiline.locale.with.accent2',null,null,'ISO-8859-1')); 83 85 $this->assertEqual('ceci est une phrase fr_CA',jLocale::get('tests1.first.locale', null, 'fr_CA')); 84 86 $this->assertEqual('this is an en_US sentence',jLocale::get('tests1.first.locale', null, 'en_US'));
