Adding a few moments to previous post. Arrays declaration. Arrays are in [] , Objects are in {}
Create a first empty array
Add to it one object, consisting of a key 'First Name' and a value 'Jane'.
Alternative way to do the above 2 operations in one go is:
Create a first empty array
- Code: Select all
<cms:set person = '[]' scope='global' is_json='1' />
Add to it one object, consisting of a key 'First Name' and a value 'Jane'.
- Code: Select all
<cms:set person. = '{"First Name" : "Jane"}' scope='global' is_json='1' />
Alternative way to do the above 2 operations in one go is:
- Code: Select all
<cms:set person = '[{"First Name" : "Jane"}]' scope='global' is_json='1' />