- Added unified default encoding. default_charset=UTF-8 and functions/extensions
use encoding settings honor default_charset.
+ (https://wiki.php.net/rfc/default_encoding)
- The php://input stream is now re-usable and can be used concurrently with
enable_post_data_reading=0.
enabled and to recognize the value -1 for never populating the global
$HTTP_RAW_POST_DATA variable, which will be default in future PHP versions.
+- Iconv:
+ Use of iconv.input_encoding, iconv.output_encoding, iconv.internal_encoding
+ raises E_DEPRECATE. Use empty value to use default_charset setting and/or
+ use input_encoding, output_encoding, internal_encoding.
+
- OpenSSL:
openssl.cafile and openssl.capath ini directives have been added to allow
global CA default specification as necessary.
+- Mbstring:
+ Use of mbstring.http_input, mbstring.http_output, mbstring.internal_encoding
+ raises E_DEPRECATE. Use empty value to use default_charset setting and/or
+ use input_encoding, output_encoding, internal_encoding.
+
+
========================================
11. Other Changes
========================================
return FAILURE;
}
if (new_value_length) {
+ if (stage & (PHP_INI_STAGE_ACTIVATE | PHP_INI_STAGE_RUNTIME)) {
+ php_error_docref("ref.iconv" TSRMLS_CC, E_DEPRECATED, "Use of iconv.input_encoding is deprecated");
+ }
OnUpdateString(entry, new_value, new_value_length, mh_arg1, mh_arg2, mh_arg3, stage TSRMLS_CC);
} else {
OnUpdateString(entry, PG(input_encoding), strlen(PG(input_encoding))+1, mh_arg1, mh_arg2, mh_arg3, stage TSRMLS_CC);
return FAILURE;
}
if (new_value_length) {
+ if (stage & (PHP_INI_STAGE_ACTIVATE | PHP_INI_STAGE_RUNTIME)) {
+ php_error_docref("ref.iconv" TSRMLS_CC, E_DEPRECATED, "Use of iconv.output_encoding is deprecated");
+ }
OnUpdateString(entry, new_value, new_value_length, mh_arg1, mh_arg2, mh_arg3, stage TSRMLS_CC);
} else {
OnUpdateString(entry, PG(output_encoding), strlen(PG(output_encoding))+1, mh_arg1, mh_arg2, mh_arg3, stage TSRMLS_CC);
return FAILURE;
}
if (new_value_length) {
+ if (stage & (PHP_INI_STAGE_ACTIVATE | PHP_INI_STAGE_RUNTIME)) {
+ php_error_docref("ref.iconv" TSRMLS_CC, E_DEPRECATED, "Use of iconv.internal_encoding is deprecated");
+ }
OnUpdateString(entry, new_value, new_value_length, mh_arg1, mh_arg2, mh_arg3, stage TSRMLS_CC);
} else {
OnUpdateString(entry, PG(internal_encoding), strlen(PG(internal_encoding))+1, mh_arg1, mh_arg2, mh_arg3, stage TSRMLS_CC);
function_exists('iconv_get_encoding') or die("skip iconv_get_encoding() is not available in this build");
?>
--INI--
+error_reporting=E_ALL & ~E_DEPRECATED
iconv.input_encoding=ISO-8859-1
iconv.internal_encoding=ISO-8859-1
iconv.output_encoding=ISO-8859-1
#PHPTestFest2009 Norway 2009-06-09 \o/
--SKIPIF--
<?php if (!extension_loaded("iconv")) { echo 'skip extension not available'; } ?>
+--INI--
+error_reporting=E_ALL & ~E_DEPRECATED
--FILE--
<?php
--SKIPIF--
<?php extension_loaded('iconv') or die('skip mbstring not available'); ?>
--INI--
+error_reporting=E_ALL & ~E_DEPRECATED
default_charset=ISO-8859-1
internal_encoding=
input_encoding=
extension_loaded('iconv') or die('skip');
function_exists('iconv_set_encoding') or die("skip iconv_set_encoding() is not available in this build");
?>
+--INI--
+error_reporting=E_ALL & ~E_DEPRECATED
--FILE--
<?php
/* Prototype : bool iconv_set_encoding(string type, string charset)
extension_loaded('iconv') or die('skip');
function_exists('iconv_strpos') or die("skip iconv_strpos() is not available in this build");
?>
+--INI--
+error_reporting=E_ALL & ~E_DEPRECATED
--FILE--
<?php
/* Prototype : int iconv_strpos(string haystack, string needle [, int offset [, string charset]])
extension_loaded('iconv') or die('skip');
function_exists('iconv_strpos') or die("skip iconv_strpos() is not available in this build");
?>
+--INI--
+error_reporting=E_ALL & ~E_DEPRECATED
--FILE--
<?php
/* Prototype : int iconv_strpos(string haystack, string needle [, int offset [, string charset]])
extension_loaded('iconv') or die('skip');
function_exists('iconv_strrpos') or die("skip iconv_strrpos() is not available in this build");
?>
+--INI--
+error_reporting=E_ALL & ~E_DEPRECATED
--FILE--
<?php
/* Prototype : proto int iconv_strrpos(string haystack, string needle [, string charset])
MBSTRG(http_input_list) = list;
MBSTRG(http_input_list_size) = size;
+ if (stage & (PHP_INI_STAGE_ACTIVATE | PHP_INI_STAGE_RUNTIME)) {
+ php_error_docref("ref.mbstring" TSRMLS_CC, E_DEPRECATED, "Use of mbstring.http_input is deprecated");
+ }
+
return SUCCESS;
}
/* }}} */
}
MBSTRG(http_output_encoding) = encoding;
MBSTRG(current_http_output_encoding) = encoding;
+
+ if (stage & (PHP_INI_STAGE_ACTIVATE | PHP_INI_STAGE_RUNTIME)) {
+ php_error_docref("ref.mbstring" TSRMLS_CC, E_DEPRECATED, "Use of mbstring.http_output is deprecated");
+ }
+
return SUCCESS;
}
/* }}} */
/* {{{ static PHP_INI_MH(OnUpdate_mbstring_internal_encoding) */
static PHP_INI_MH(OnUpdate_mbstring_internal_encoding)
{
+ if (stage & (PHP_INI_STAGE_ACTIVATE | PHP_INI_STAGE_RUNTIME)) {
+ php_error_docref("ref.mbstring" TSRMLS_CC, E_DEPRECATED, "Use of mbstring.internal_encoding is deprecated");
+ }
+
if (OnUpdateString(entry, new_value, new_value_length, mh_arg1, mh_arg2, mh_arg3, stage TSRMLS_CC) == FAILURE) {
return FAILURE;
}
- if (stage == PHP_INI_STAGE_STARTUP || stage == PHP_INI_STAGE_SHUTDOWN
- || stage == PHP_INI_STAGE_RUNTIME) {
+
+ if (stage & (PHP_INI_STAGE_STARTUP | PHP_INI_STAGE_SHUTDOWN | PHP_INI_STAGE_RUNTIME)) {
if (new_value_length) {
return _php_mb_ini_mbstring_internal_encoding_set(new_value, new_value_length TSRMLS_CC);
} else {
Bug #48697 (mb_internal_encoding() value gets reset by parse_str() or mb_parse_str()
--SKIPIF--
<?php extension_loaded('mbstring') or die('skip mbstring not available'); ?>
+--INI--
+error_reporting=E_ALL & ~E_DEPRECATED
--FILE--
<?php
ini_set('mbstring.internal_encoding', 'ISO-8859-15');
--SKIPIF--
<?php extension_loaded('mbstring') or die('skip mbstring not available'); ?>
--INI--
+error_reporting=E_ALL & ~E_DEPRECATED
default_charset=Shift_JIS
internal_encoding=
input_encoding=
--TEST--
zend multibyte (2)
---XFAIL--
-https://bugs.php.net/bug.php?id=66582
--INI--
zend.multibyte=On
zend.script_encoding=UTF-8
--TEST--
zend multibyte (6)
---XFAIL--
-https://bugs.php.net/bug.php?id=66582
--INI--
zend.multibyte=On
zend.script_encoding=EUC-JP
--XFAIL--
https://bugs.php.net/bug.php?id=66582
--INI--
+error_reporting=E_ALL & ~E_DEPRECATED
zend.multibyte=On
zend.script_encoding=ISO-8859-1
mbstring.internal_encoding=EUC-JP
--TEST--
zend multibyte (8)
--SKIPIF--
+--XFAIL--
+https://bugs.php.net/bug.php?id=66582
--INI--
zend.multibyte=On
zend.script_encoding=ISO-8859-1
--XFAIL--
https://bugs.php.net/bug.php?id=66582
--INI--
+error_reporting=E_ALL & ~E_DEPRECATED
zend.multibyte=On
zend.script_encoding=cp1251
mbstring.internal_encoding=UTF-8
--TEST--
zend multibyte (10)
--SKIPIF--
+--XFAIL--
+https://bugs.php.net/bug.php?id=66582
--INI--
zend.multibyte=1
--FILE--
--TEST--
zend multibyte (11)
--SKIPIF--
+--XFAIL--
+https://bugs.php.net/bug.php?id=66582
--INI--
zend.multibyte=1
--FILE--