Property | Type | Description | |
---|---|---|---|
$encodeOptions | the encoding options passed to [[Json::encode()]]. For more details please refer to
|
||
$prettyPrint | whether to format the output in a readable "pretty" format. This can be useful for debugging purpose. If this is true, JSON_PRETTY_PRINT will be added to [[encodeOptions]]. Defaults to false. This property has no effect, when [[useJsonp]] is true. | ||
$useJsonp | whether to use JSONP response format. When this is true, the [[Response::data|response data]] must be an array consisting of data and callback members. The latter should be a JavaScript function name while the former will be passed to this function as a parameter. |
Method | Description | |
---|---|---|
format ( |
Formats the specified response. |
Method | Description | |
---|---|---|
formatJson ( |
Formats response data in JSON format. | |
formatJsonp ( |
Formats response data in JSONP format. |
public format ( |
||
$response | the response to be formatted. |
protected formatJson ( |
||
$response |
protected formatJsonp ( |
||
$response |
public $encodeOptions |
public $prettyPrint |
public $useJsonp |