php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Doc Bug #68733 RFC7159 JSON allows top-level scalars
Submitted: 2015-01-03 04:20 UTC Modified: 2015-01-06 00:43 UTC
From: lolphpbugs at rebertia dot com Assigned: aharvey (profile)
Status: Closed Package: Documentation problem
PHP Version: 5.6.4 OS:
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: lolphpbugs at rebertia dot com
New email:
PHP Version: OS:

 

 [2015-01-03 04:20 UTC] lolphpbugs at rebertia dot com
Description:
------------
---
From manual page: http://www.php.net/intro.json
---

This page of your docs contains the following note:

> Note:
> PHP implements a superset of JSON - it will also encode and decode scalar types and NULL. The JSON standard only supports these values when they are nested inside an array or an object.

This statement regarding the JSON standard is inaccurate as of RFC 7159 (https://tools.ietf.org/html/rfc7159 ):

> Appendix A.  Changes from RFC 4627
> [...]
>    o  Changed the definition of "JSON text" so that it can be any JSON
>       value, removing the constraint that it be an object or array.


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2015-01-06 00:43 UTC] aharvey@php.net
Automatic comment from SVN on behalf of aharvey
Revision: http://svn.php.net/viewvc/?view=revision&revision=335638
Log: Update the note on JSON standard conformance.

Fixes doc bug #68733 (RFC7159 JSON allows top-level scalars).
 [2015-01-06 00:43 UTC] aharvey@php.net
-Status: Open +Status: Closed -Assigned To: +Assigned To: aharvey
 [2015-01-06 00:43 UTC] aharvey@php.net
This bug has been fixed in the documentation's XML sources. Since the
online and downloadable versions of the documentation need some time
to get updated, we would like to ask you to be a bit patient.

Thank you for the report, and for helping us make our documentation better.

Updated to mention the newer RFC and ECMA standard.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sun Dec 22 04:01:29 2024 UTC