Item Extension functionality allows add additional inputs for custom information for Item Posts.
Feature consist of two parts:
- Item Extension settings on admin page Citadela Directory > Item Extension where can be created additional inputs,
- Item Extension block which show on Item Detail pages information from inputs.
Settings are available in Citadela Directory > Item Extension admin page. Available are settings:
- Enable – turn on Item Extension functionality. If disabled, created inputs are not available on edit screen of Item posts and Item Extension block doesn’t show any information on the frontend.
- Group name – custom label of tab with new inputs on Item Edit page.
Inputs can be reordered using drag & drop to show inputs in wanted order. In the same order are displayed also information on the frontend.
Available options for each new input:
- Input type – selection of available input types
- Input label – label text displayed with input on Item edit screen and also displayed with inserted value on the frontend of Item Post
- Input description – help text displayed on Item edit screen with input, should include description of value expected in the input
- Input identifier – unique identifier that is used to recognize input, data are saved under this key in database as post meta for each Item Post with prefix “_citadela_item_extension_”
Available input types:
Some of inputs allow you to fill more information with created input. Find detailed information below.
With select input you should defined which values will be available in selection on Item edit screen.
Each option is inserted in one line of Choices input in
value_identifier : Value text.
In example, to use selection of colors like Red, Blue and Green, should be inserted:
red : Red blue : Blue green : Green
If there should be available also option with no value selected in case the selection of value is not required, can be used:
: Choose some color red : Red blue : Blue green : Green
Option “Choose some color” doesn’t store any value so the selection doesn’t save any value.
With URL input can be on Item edit screen displayed also additional input for text which is displayed instead of full url on the frontend.
In order to show this input on Item Edit page with URL input, just select option Show link label input in settings of your URL input.
If this text isn’t filled for Item post, full URL inserted in URL input is displayed on the frontend.
With simple number value can be displayed also unit of value.
In settings of number input simply insert your unit text in Unit field and this text will be displayed with number value on Item detail page.
Position of unit can be defined via selection Unit position to show unit on the left or right side of number value.
In example, if your number input would store price value, you can fill Unit field with text $ and defined Unit position to value left.
Now for example value 500 inserted in Item edit page in this number input will be displayed on the frontend like $ 500.