php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Doc Bug #77881 JSON_INVALID_UTF8_(IGNORE|SUBSTITUTE) constants are not documented
Submitted: 2019-04-12 08:55 UTC Modified: 2019-04-16 18:36 UTC
From: php at yopmail dot com Assigned: girgias (profile)
Status: Closed Package: JSON related
PHP Version: Irrelevant OS:
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: php at yopmail dot com
New email:
PHP Version: OS:

 

 [2019-04-12 08:55 UTC] php at yopmail dot com
Description:
------------
https://github.com/php/php-src/pull/2606 introduced two new constants
JSON_INVALID_UTF8_IGNORE and JSON_INVALID_UTF8_SUBSTITUTE
for the json_decode() and json_encode() functions
in PHP 7.2.0.

They are only briefly mentioned in the "PHP 7 ChangeLog" https://www.php.net/ChangeLog-7.php
and listed (without links) on the "Migrating from PHP 7.1.x to PHP 7.2.x" "New global constants" page https://www.php.net/manual/en/migration72.constants.php

But there is no mention of them in the reference pages:

 * https://www.php.net/manual/en/json.constants.php
 * https://www.php.net/manual/en/function.json-decode.php
 * https://www.php.net/manual/en/function.json-encode.php

(whereas there is for the JSON_THROW_ON_ERROR constant introduced later in PHP 7.3.0)


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2019-04-16 17:26 UTC] girgias@php.net
-Summary: 7.2 JSON_INVALID_UTF8_(IGNORE|SUBSTITUTE) constants are not documented +Summary: JSON_INVALID_UTF8_(IGNORE|SUBSTITUTE) constants are not documented -Status: Open +Status: Verified
 [2019-04-16 18:14 UTC] girgias@php.net
Automatic comment from SVN on behalf of girgias
Revision: http://svn.php.net/viewvc/?view=revision&revision=347249
Log: Add JSON_INVALID_UTF8_IGNORE and JSON_INVALID_UTF8_SUBSTITUTE constants doc.
Partial fix to Doc Bug #77881
 [2019-04-16 18:31 UTC] girgias@php.net
Automatic comment from SVN on behalf of girgias
Revision: http://svn.php.net/viewvc/?view=revision&revision=347250
Log: Add JSON constants to changelog.
Fixes:
Doc Bug #77798
Doc Bug #77811
Doc Bug #77881
 [2019-04-16 18:36 UTC] girgias@php.net
-Status: Verified +Status: Closed -Assigned To: +Assigned To: girgias
 
PHP Copyright © 2001-2020 The PHP Group
All rights reserved.
Last updated: Wed Dec 02 05:01:23 2020 UTC