FW: php4 /ext/standard/tests/strings htmlentities15.phpt htmlentities16.phpt

From: Date: Mon, 24 Mar 2003 19:40:34 +0000
Subject: FW: php4 /ext/standard/tests/strings htmlentities15.phpt htmlentities16.phpt
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-19741@lists.php.net to get a copy of this message
> -----Original Message----- > From: Moriyoshi Koizumi [mailto:moriyoshi@at.wakwak.com] > Sent: 24 March 2003 19:21 > To: php-cvs@lists.php.net > Subject: cvs: php4 /ext/standard/tests/strings htmlentities15.phpt > htmlentities16.phpt > > > moriyoshi Mon Mar 24 14:21:20 2003 EDT > > Added files: > /php4/ext/standard/tests/strings htmlentities15.phpt > htmlentities16.phpt > Log: > Added test cases for new functionality > > > > Index: php4/ext/standard/tests/strings/htmlentities15.phpt > +++ php4/ext/standard/tests/strings/htmlentities15.phpt > --TEST-- > htmlentities() test 15 (setlocale / KOI8-R) > --INI-- > output_handler= > default_charset= > mbstring.internal_encoding=none > --SKIPIF-- > <?php > $result = (bool)setlocale(LC_CTYPE, "ru_RU.koi8r"); > if (!$result || preg_match('/koi8/i', setlocale(LC_CTYPE, 0)) == 0) { > die("skip setlocale() failed\n"); > } > ?> > --FILE-- > <?php > setlocale(LC_CTYPE, "ru_RU.koi8r"); > $str = "ÒÏÓËÏÛÎÙÊ"; > var_dump($str, htmlentities($str, ENT_QUOTES, '')); > ?> > --EXPECT-- > string(9) "ÒÏÓËÏÛÎÙÊ" > string(63) > > "&#1088;&#1086;&#1089;&#1082;&#1086;&#1096;&#1085;&#1099;&#1081;" > > Index: php4/ext/standard/tests/strings/htmlentities16.phpt > +++ php4/ext/standard/tests/strings/htmlentities16.phpt > --TEST-- > htmlentities() test 16 (mbstring / cp1251) > --INI-- > output_handler= > --SKIPIF-- > <?php > extension_loaded("mbstring") or die("skip mbstring not > available\n"); > mb_internal_encoding('cp1251'); > $php_errormsg = NULL; > > @htmlentities("\x88\xa9\xd2\xcf\xd3\xcb\xcf\xdb\xce\xd9\xca", > ENT_QUOTES, ''); > if ($php_errormsg) { > die("skip cp1251 chracter set is not supported on > this platform.\n"); > } > ?> > --FILE-- > <?php > mb_internal_encoding('cp1251'); > $str = "\x88\xa9\xf0\xee\xf1\xea\xee\xf8\xed\xfb\xe9"; > var_dump($str, htmlentities($str, ENT_QUOTES, '')); > ?> > --EXPECT-- > string(11) "ˆ©ÒÏÓËÏÛÎÙÊ" > string(63) > > "&euro;&copy;&#1088;&#1086;&#1089;&#1082;&#1086;&#1096;&#1085;&#10 > 99;&#1081;" > > >

« previous php.cvs (#19741) next »