锟斤拷锟叫筹拷锟斤拷锟缴达拷锟斤拷展锟斤拷锟藉,锟揭斤拷锟节达拷锟斤拷展锟斤拷锟斤拷锟斤拷 PHP 锟斤拷锟斤拷锟斤拷锟斤拷时锟斤拷态锟斤拷锟斤拷时锟斤拷锟矫★拷
锟斤拷锟铰筹拷锟斤拷锟斤拷示锟斤拷 json_last_error() 锟斤拷锟斤拷锟截的达拷锟斤拷锟斤拷锟酵★拷
JSON_ERROR_NONE
(integer)
JSON_ERROR_DEPTH
(integer)
JSON_ERROR_STATE_MISMATCH
(integer)
JSON_ERROR_CTRL_CHAR
(integer)
JSON_ERROR_SYNTAX
(integer)
JSON_ERROR_UTF8
(integer)
JSON_ERROR_RECURSION
(integer)
JSON_PARTIAL_OUTPUT_ON_ERROR
option was
given, NULL
will be encoded in the place of the recursive reference.
Available since PHP 5.5.0.
JSON_ERROR_INF_OR_NAN
(integer)
NAN
or INF
.
If the JSON_PARTIAL_OUTPUT_ON_ERROR
option was
given, 0 will be encoded in the place of these
special numbers.
Available since PHP 5.5.0.
JSON_ERROR_UNSUPPORTED_TYPE
(integer)
JSON_PARTIAL_OUTPUT_ON_ERROR
option was
given, NULL
will be encoded in the place of the unsupported value.
Available since PHP 5.5.0.
JSON_ERROR_INVALID_PROPERTY_NAME
(integer)
JSON_ERROR_UTF16
(integer)
锟斤拷锟斤拷某锟斤拷锟斤拷锟斤拷院锟� json_decode() 锟斤拷 form 选锟斤拷锟斤拷使锟矫★拷
JSON_BIGINT_AS_STRING
(integer)
JSON_OBJECT_AS_ARRAY
(integer)
TRUE
.
Available since PHP 5.4.0.
锟斤拷锟斤拷某锟斤拷锟斤拷锟斤拷院锟� json_encode() 锟斤拷 form 选锟斤拷锟斤拷使锟矫★拷
JSON_HEX_TAG
(integer)
JSON_HEX_AMP
(integer)
JSON_HEX_APOS
(integer)
JSON_HEX_QUOT
(integer)
JSON_FORCE_OBJECT
(integer)
JSON_NUMERIC_CHECK
(integer)
JSON_PRETTY_PRINT
(integer)
JSON_UNESCAPED_SLASHES
(integer)
JSON_UNESCAPED_UNICODE
(integer)
JSON_PARTIAL_OUTPUT_ON_ERROR
(integer)
JSON_PRESERVE_ZERO_FRACTION
(integer)
JSON_UNESCAPED_LINE_TERMINATORS
(integer)
JSON_UNESCAPED_UNICODE
is supplied. It uses the same
behaviour as it was before PHP 7.1 without this constant.
Available since PHP 7.1.0.