rfc:json_encode_indentation
Differences
This shows you the differences between two versions of the page.
Next revision | Previous revisionNext revisionBoth sides next revision | ||
rfc:json_encode_indentation [2021/06/03 13:49] – created tdgroot | rfc:json_encode_indentation [2021/06/03 15:23] – tdgroot | ||
---|---|---|---|
Line 3: | Line 3: | ||
* Date: 2021-06-03 | * Date: 2021-06-03 | ||
* Author: Timon de Groot, tdegroot96@gmail.com | * Author: Timon de Groot, tdegroot96@gmail.com | ||
+ | * Implementation: | ||
* Status: Draft | * Status: Draft | ||
- | |||
===== Introduction ===== | ===== Introduction ===== | ||
Line 19: | Line 19: | ||
$data = [ | $data = [ | ||
' | ' | ||
- | ' | + | ' |
]; | ]; | ||
- | echo json_encode($data, | + | echo json_encode([' |
+ | echo json_encode($data, | ||
+ | echo json_encode([' | ||
+ | echo json_encode([' | ||
?> | ?> | ||
</ | </ | ||
- | < | + | < |
+ | { | ||
+ | " | ||
+ | } | ||
{ | { | ||
" | " | ||
" | " | ||
- | | + | 2 |
- | 1, | + | |
- | | + | |
- | 3 | + | |
] | ] | ||
+ | } | ||
+ | { | ||
+ | 🚀🚀" | ||
+ | } | ||
+ | { | ||
+ | " | ||
} | } | ||
</ | </ |
rfc/json_encode_indentation.txt · Last modified: 2022/07/19 15:23 by cmb