2014-03-19 21:33:39 +00:00
|
|
|
<?xml version="1.0" encoding="utf-8"?>
|
2014-05-25 11:29:08 +00:00
|
|
|
<!-- $Revision$ -->
|
2014-03-19 21:33:39 +00:00
|
|
|
|
|
|
|
<sect1 xml:id="migration56.deprecated">
|
|
|
|
<title>Deprecated features in PHP 5.6.x</title>
|
|
|
|
|
|
|
|
<sect2 xml:id="migration56.deprecated.incompatible-context">
|
|
|
|
<title>Calls from incompatible context</title>
|
|
|
|
|
|
|
|
<para>
|
|
|
|
Methods called from an incompatible context are now deprecated, and will
|
|
|
|
generate <constant>E_DEPRECATED</constant> errors when invoked instead of
|
|
|
|
<constant>E_STRICT</constant>. Support for these calls will be removed in
|
|
|
|
a future version of PHP.
|
|
|
|
</para>
|
|
|
|
|
|
|
|
<para>
|
|
|
|
An example of such a call is:
|
|
|
|
</para>
|
|
|
|
|
|
|
|
<informalexample>
|
|
|
|
<programlisting role="php">
|
|
|
|
<![CDATA[
|
|
|
|
<?php
|
|
|
|
class A {
|
|
|
|
function f() { echo get_class($this); }
|
|
|
|
}
|
|
|
|
|
|
|
|
class B {
|
|
|
|
function f() { A::f(); }
|
|
|
|
}
|
|
|
|
|
|
|
|
(new B)->f();
|
|
|
|
?>
|
|
|
|
]]>
|
|
|
|
</programlisting>
|
|
|
|
&example.outputs;
|
|
|
|
<screen>
|
|
|
|
<![CDATA[
|
|
|
|
Deprecated: Non-static method A::f() should not be called statically, assuming $this from incompatible context in - on line 7
|
|
|
|
B
|
|
|
|
]]>
|
|
|
|
</screen>
|
|
|
|
</informalexample>
|
|
|
|
</sect2>
|
|
|
|
|
|
|
|
<sect2 xml:id="migration56.deprecated.raw-post-data">
|
2021-02-24 13:32:08 +00:00
|
|
|
<title><varname>$HTTP_RAW_POST_DATA</varname> and <literal>always_populate_raw_post_data</literal></title>
|
2014-03-19 21:33:39 +00:00
|
|
|
|
|
|
|
<para>
|
2021-02-24 13:32:08 +00:00
|
|
|
<literal>always_populate_raw_post_data</literal>
|
2015-04-05 06:36:38 +00:00
|
|
|
will now generate an <constant>E_DEPRECATED</constant> error when
|
|
|
|
<varname>$HTTP_RAW_POST_DATA</varname> is populated.
|
2014-03-19 21:33:39 +00:00
|
|
|
New code should use
|
|
|
|
<link linkend="wrappers.php.input"><literal>php://input</literal></link>
|
|
|
|
instead of <varname>$HTTP_RAW_POST_DATA</varname>, which will be removed
|
|
|
|
in a future release. You can opt in for the new behaviour (in which
|
2015-04-05 06:36:38 +00:00
|
|
|
<varname>$HTTP_RAW_POST_DATA</varname> is never defined hence no
|
|
|
|
<constant>E_DEPRECATED</constant> error will be generated) by setting
|
2021-02-24 13:32:08 +00:00
|
|
|
<literal>always_populate_raw_post_data</literal>
|
2014-03-19 21:33:39 +00:00
|
|
|
to <literal>-1</literal>.
|
|
|
|
</para>
|
|
|
|
</sect2>
|
|
|
|
|
2014-08-28 04:53:06 +00:00
|
|
|
<sect2 xml:id="migration56.deprecated.iconv-mbstring-encoding">
|
|
|
|
<title><link linkend="book.iconv">iconv</link> and <link linkend="book.mbstring">mbstring</link> encoding settings</title>
|
|
|
|
|
|
|
|
<para>
|
|
|
|
The <link linkend="book.iconv">iconv</link> and
|
|
|
|
<link linkend="book.mbstring">mbstring</link> configuration options related
|
|
|
|
to encoding have been deprecated in favour of
|
|
|
|
<link linkend="ini.default-charset"><parameter>default_charset</parameter></link>.
|
|
|
|
The deprecated options are:
|
|
|
|
</para>
|
|
|
|
|
|
|
|
<itemizedlist>
|
|
|
|
<listitem>
|
|
|
|
<simpara>
|
|
|
|
<link linkend="ini.iconv.input-encoding"><parameter>iconv.input_encoding</parameter></link>
|
|
|
|
</simpara>
|
|
|
|
</listitem>
|
|
|
|
<listitem>
|
|
|
|
<simpara>
|
|
|
|
<link linkend="ini.iconv.output-encoding"><parameter>iconv.output_encoding</parameter></link>
|
|
|
|
</simpara>
|
|
|
|
</listitem>
|
|
|
|
<listitem>
|
|
|
|
<simpara>
|
|
|
|
<link linkend="ini.iconv.internal-encoding"><parameter>iconv.internal_encoding</parameter></link>
|
|
|
|
</simpara>
|
|
|
|
</listitem>
|
|
|
|
<listitem>
|
|
|
|
<simpara>
|
|
|
|
<link linkend="ini.mbstring.http-input"><parameter>mbstring.http_input</parameter></link>
|
|
|
|
</simpara>
|
|
|
|
</listitem>
|
|
|
|
<listitem>
|
|
|
|
<simpara>
|
|
|
|
<link linkend="ini.mbstring.http-output"><parameter>mbstring.http_output</parameter></link>
|
|
|
|
</simpara>
|
|
|
|
</listitem>
|
|
|
|
<listitem>
|
|
|
|
<simpara>
|
|
|
|
<link linkend="ini.mbstring.internal-encoding"><parameter>mbstring.internal_encoding</parameter></link>
|
|
|
|
</simpara>
|
|
|
|
</listitem>
|
|
|
|
</itemizedlist>
|
|
|
|
</sect2>
|
2014-03-19 21:33:39 +00:00
|
|
|
</sect1>
|
|
|
|
|
|
|
|
<!-- Keep this comment at the end of the file
|
|
|
|
Local variables:
|
|
|
|
mode: sgml
|
|
|
|
sgml-omittag:t
|
|
|
|
sgml-shorttag:t
|
|
|
|
sgml-minimize-attributes:nil
|
|
|
|
sgml-always-quote-attributes:t
|
|
|
|
sgml-indent-step:1
|
|
|
|
sgml-indent-data:t
|
|
|
|
indent-tabs-mode:nil
|
|
|
|
sgml-parent-document:nil
|
|
|
|
sgml-default-dtd-file:"~/.phpdoc/manual.ced"
|
|
|
|
sgml-exposed-tags:nil
|
|
|
|
sgml-local-catalogs:nil
|
|
|
|
sgml-local-ecat-files:nil
|
|
|
|
End:
|
|
|
|
vim600: syn=xml fen fdm=syntax fdl=2 si
|
|
|
|
vim: et tw=78 syn=sgml
|
|
|
|
vi: ts=1 sw=1
|
|
|
|
-->
|