更新日志

对本扩展的类/函数/方法有以下更新。

VersionFunctionDescription
8.1.0html_entity_decodeflags changed from ENT_COMPAT to ENT_QUOTES | ENT_SUBSTITUTE | ENT_HTML401.
8.0.0html_entity_decodeencoding is nullable now.
 metaphoneThe function returned false on failure.
 parse_strresult 是必须项。
 soundexPrior to this version, calling the function with an empty string returned false for no particular reason.
 sprintf此函数失败时不再返回 false 。
 str_word_countcharacters 可为空(Nullable)类型。
 substr函数将返回一个空字符串, 在此之前返回 false 。
 substr现在 length 允许为 null。
 substr_countlength 可以为空(nullable)。
 vsprintf此函数失败时不再返回 false 。
7.4.0implode把参数 glue 放到 pieces 的后面已被废弃(就是不按文档中的顺序传递参数)。
7.2.18, 7.3.5substr_compareoffset 现在可能等于 main_str。
7.2.0number_formatnumber_format 现在无法返回 -0,之前可能返回 -0,因为 number 可能会是 -0.01。
 parse_str不带第二个参数的情况下使用 parse_str 会产生 E_DEPRECATED 警告。
7.1.0str_shuffle内置的随机算法从 libc rand 函数改成了梅森旋转演伪随机数发生算法。
 stripos开始支持负数的 offset。
 strpos开始支持负数的 offset。
 substr_count开始支持负数的 offset 和 length。
5.6.5cryptWhen the failure string "*0" is given as the salt, "*1" will now be returned for consistency with other crypt implementations. Prior to this version, PHP 5.6 would incorrectly return a DES hash.
5.6.0cryptRaise E_NOTICE security warning if salt is omitted.
 htmlentitiesThe default value for the encoding parameter was changed to be the value of the default_charset configuration option.
 htmlspecialcharsThe default value for the encoding parameter was changed to be the value of the default_charset configuration option.
5.5.21cryptWhen the failure string "*0" is given as the salt, "*1" will now be returned for consistency with other crypt implementations. Prior to this version, PHP 5.5 (and earlier branches) would incorrectly return a DES hash.
5.5.1hex2bin如果输入的字符串是无效的十六进制字符串则抛出一个警告,
5.4.32, 5.5.16ucwords增加了 delimiters 参数。
5.4.4hex2bin如果输入的字符串有多余将抛出异常。 PHP 5.4.0 起字符串将被静默地接受,但是最后的字节会被截断。
5.4.0get_html_translation_tableThe default value for the encoding parameter was changed to UTF-8.
 get_html_translation_tableThe constants ENT_HTML401, ENT_XML1, ENT_XHTML and ENT_HTML5 were added.
 htmlentities增加常量 ENT_SUBSTITUTE、 ENT_DISALLOWED、 ENT_HTML401、 ENT_XML1、 ENT_XHTML、 ENT_HTML5。
 htmlentitiesencoding 参数的默认值改成 UTF-8。
 htmlspecialchars增加常量 ENT_SUBSTITUTE、 ENT_DISALLOWED、 ENT_HTML401、 ENT_XML1、 ENT_XHTML、 ENT_HTML5。
 htmlspecialcharsencoding 参数的默认值改成 UTF-8。
 htmlspecialchars_decode增加了 ENT_HTML401、ENT_XML1、 ENT_XHTML 和 ENT_HTML5 等常量。
 number_formatThis function now supports multiple bytes in dec_point and thousands_sep. Only the first byte of each separator was used in older versions.
5.3.7cryptAdded $2x$ and $2y$ Blowfish modes to deal with potential high-bit attacks.
5.3.4get_html_translation_tableThe encoding parameter was added.
 strip_tagsstrip_tags ignores self-closing XHTML tags in allowable_tags.
5.3.2crypt基于 Ulrich Drepper 的实现,新增基于 SHA-256 算法和 SHA-512 算法的 crypt。
 crypt修正了 Blowfish 算法由于非法循环导致的问题,返回“失败”字符串(“*0” 或 “*1”)而不是转而使用 DES 算法。
5.3.0cryptPHP 现在包含了它自己的 MD5 Crypt 实现,包括标准 DES 算法,扩展的 DES 算法以及 Blowfish 算法。如果系统缺乏相应的实现,那么 PHP 将使用它自己的实现。
 htmlentities增加常量 ENT_IGNORE。
 htmlspecialchars增加常量 ENT_IGNORE。
 nl2br新增可选的 is_xhtml 参数。在此之前,总是插入 '<br />'。
 setlocaleThis function now throws an E_DEPRECATED notice if a string is passed to the category parameter instead of one of the LC_* constants.
 stristr新增可选的 before_needle 参数。
 strstr新增可选的 before_needle 参数。
5.2.5addcslashesThe escape sequences \v and \f were added.
5.2.3htmlentities增加参数 double_encode。
 htmlspecialchars增加参数 double_encode。
5.0.0strip_tagsstrip_tags 变为二进制安全的。
 strrpos参数 needle 可以是一个多字符的字符串。
 strrpos引入 offset 参数。
4.3.3substr_replaceAll parameters now accept arrays.
4.3.0stristrstristr 变为二进制安全的。
 strrchr该函数是二进制安全的。
 strspn新增 start 和 length 参数。
 strstrstrstr 成为二进制安全的。
4.2.3strcoll函数在 Win32 平台可用。
7i24.Com