PHP 7.1.12 Released

Migrating from PHP 5.5.x to PHP 5.6.x

Table of Contents

Most improvements in PHP 5.6.x have no impact on existing code. There are a few incompatibilities and new features that should be considered, and code should be tested before switching PHP versions in production environments.

See also the migration guides for PHP versions 5.0.x, 5.1.x, 5.2.x, 5.3.x, 5.4.x and 5.5.x.

add a note add a note

User Contributed Notes 1 note

up
0
offlinewan at gmail dot com
7 months ago
Plese notice that default POST data parsing has changed.
php 5.5 with "foo=bar&baz" received
[
  "foo" => "bar"
]
and php 5.6 with same input receives:
[
  "foo" => "bar",
  "baz" => ""
]

Tested via curl --data 'foo=bar&baz' http://localhost

It can create a problem when earlier json came without correct content-type header.
e.g. {"foo":"bar"} in php 5.5 $_POST was
[
]
and in php 5.6 will be
[
  "{\"foo\":\"\bar\"}" => ""
]

Tested via curl --data '{"foo":"bar"}' http://localhost
To Top