Extend Fields

Create one Extend FieldTop of Page

To create one Content Field:

  • In Ionize, go to Content > Extend Fields
  • Click on the button "New Extend Field"
SettingDescription
Parent Parent type for wich this Extend Field will be available
Label Displayed label of the extend field
Name Name of the extended field.
Must be lowercase and unique
Type Kind of data.
Input : A simple text input
Textarea : A simple textarea
Textarea + Editor : The textarea will be displayed with a Wysiwyg texteditor
Checkbox, Radio, Select : List of values
Can be translated When activated, this extended field can have values for each installed language
Values Need to be used when checkbox, radio or select type is chosen.
Format : <value>:<label>
Example : 1:Red
Will be displayed :
Default value Used value when no value is set by the Editor.
In case of checkbox, radio or select, the value must be used.
Description Help displayed on the backend label.

Set the Extend Field valueTop of Page

Once created, the extended field will appear in its context panel.

An article extended field will appear on the article edition panel.

Display Extend Fields in viewsTop of Page

Extend Fields are displayed in views through a dedicated tag : <ion:extend />

This tag must be used in the context of the parent type for which the Extend Field is defined.

In other words, if you have defined one extend field which has the name "color", the tag <ion:extend:color /> will give you access to this field.

In case of radio, checkbox or select, the returned value will be the key.

<!-- Current page -->
<ion:page>

<!-- Articles linked to the current page -->
<ion:articles>

<ion:article>

<!-- Display one simple Extend Field (input or textarea type) -->
<ion:extend:description>

<!-- Label of the Extend Field -->
<ion:label/>

<!-- Value of the Extend Field -->
<ion:value />

</ion:extend:description>


<!-- Display one checkbox, radio or select Extend Field -->
<ion:extend:difficulty>

<!-- Display all the available options -->
<p>
Available options: <br/>
<ion:options>
<ion:value/> : <ion:label/><br/>
</ion:options>
</p>

<!-- Display the values selected by the editor -->
<p>
Values: <br/>
<ion:values>
<ion:value/> : <ion:label/><br/>
</ion:values>
</p>

</ion:extend:difficulty>

</ion:article>

</ion:articles>

</ion:page>