W3cubDocs

/CakePHP 3.4

Function pj

json pretty print convenience function.

In terminals this will act similar to using json_encode() with JSON_PRETTY_PRINT directly, when not run on cli will also wrap

<

pre> tags around the output of given variable. Similar to pr().

This function returns the same variable that was passed.

See: pr()
Link: http://book.cakephp.org/3.0/en/core-libraries/global-constants-and-functions.html#pj
Copyright: Copyright (c) Cake Software Foundation, Inc. (http://cakefoundation.org)
License: MIT License
Located at Core/functions.php
pj( mixed $var )

Parameters summary

mixed $var Variable to print out.

Returns

  • mixed the same $var that was passed to this function

© 2005–2017 The Cake Software Foundation, Inc.
Licensed under the MIT License.
CakePHP is a registered trademark of Cake Software Foundation, Inc.
We are not endorsed by or affiliated with CakePHP.
https://api.cakephp.org/3.4/function-pj.html