Item.Group.Fields
Summary
The Item.Group.Fields
loop lets you display available field's data within the item type's group.
Examples
Basic usage
Notice the use of @item.GetValue to get data from the loop variable.
If you just write @GetValue, the data will be taken from outside the loop.
Similarly, you have to use @item.GetLoop to use loops inside a loop.
Check if the loop exists
Example of usage
The following general example illustrates how to use a loop construct.
Check if the loop exists
Available tags
Item.[FieldSystemName]
Returns the value from the item field that is filled on a page/paragraph.
@GetString("Item.[FieldSystemName]")
Item.Field.SystemName
Returns the system name of the item field.
@GetString("Item.Field.SystemName")
Item.Field.Type
Returns the type of the item field, e.g. File, Text.
@GetString("Item.Field.Type")
Item.Field.Value
Returns the value from the item field that is filled on a page/paragraph.
@GetString("Item.Field.Value")
Available loops
Item.[FieldSystemName].ListOfFiles
The Item.[FieldSystemName].ListOfFiles
loop lists all files that are selected with the Folder item type and lets you display various information about the files.
@foreach (LoopItem item in GetLoop("Item.[FieldSystemName].ListOfFiles")){ <p>@item.GetValue("TagName")</p> }
Item.[FieldSystemName].Options
The Item.[FieldSystemName].Options
loop lets you display information about options for item field with the [FieldSystemName] system name.
@foreach (LoopItem item in GetLoop("Item.[FieldSystemName].Options")){ <p>@item.GetValue("TagName")</p> }
Item.[FieldSystemName].Validators
The Item.[FieldSystemName].Validators
loop lets you display information about all validators of the item field with [FieldSystemName] system name..
@foreach (LoopItem item in GetLoop("Item.[FieldSystemName].Validators")){ <p>@item.GetValue("TagName")</p> }