Skip to Main Content
Categories Expression Engine
Created by Mark Stuart-Walker
Created on Apr 24, 2025

New FIELDS() to return a JSON object

Please, fill in the below fields to enable the processing of your idea.

Who would benefit?

Anyone wishing to programmatically examine the values of specific/all fields

What impact would it make?

Improved programmed access to the local fields and their values

How should it work?

Add a new function FIELDS() which returns a JSON object of field values indexed by their field type ids

An optional parameter can contain comma separated list of fields to collect. When omitted it implies all fields.


Why is it needed?

FIELDVALUES() returns just a linear list of values but doesn't identify the field type id of each value and the order is not defined either.
=FIELDVALUES(currentFieldSetOnly, [categoryId])



https://community.inriver.com/hc/en-us/articles/13448180101916-A-list-of-all-available-functions-in-the-Expression-Engine-with-examples


  • Attach files