Settings Docs
Custom fields
Custom fields let your account add its own information to every content type with language versions. Editors fill them in with each language version, and your site's templates can show them.
最後更新:
Open Settings → Custom fields as an account owner or admin. Fields belong to the account, and each is for one content type: Pages, Posts, News, Events, Blogs, Partials or Resources. Projects and Newsletters keep their text on the item itself and don't take custom fields.
Add a field
Choose New field and fill in:
- For: the content type the field belongs to.
- Key: how templates refer to the field, such as
price: lowercase letters, digits and underscores, starting with a letter. Leave it blank to make one from the label. Each key is used once per content type, and it can't change later. - Label: what editors see.
- Type:
- Text: one line, up to 255 characters.
- Long text: several lines, up to 10,000 characters.
- Number: whole or decimal, such as
12or-1.5. - Date: a calendar date.
- Yes/no: a tick box.
- Choice: one of the Options you list, one per line (up to 50).
- Web address: an address starting with
https://orhttp://, or a path on the site starting with/.
- Help text: a hint shown under the field.
- Order: fields with lower numbers come first.
- Required: a language version can't be saved while the field is empty. Yes/no fields always have a value, so they're never required.
- Sites: tick sites to show the field only there. With none ticked, it shows on every site of the account.
An account can define up to 50 fields for each content type.
Fill in fields
The language editor of each item of those types shows the fields under Custom fields. Values are kept for each language version, so a translation has its own. When a value doesn't fit its field (a word in a number field, an option that isn't listed, a required field left empty), nothing is saved and the field is marked so you can correct it.
Duplicating an item copies its values. Values are part of each saved version, so history shows when they changed, and restoring an earlier version restores its values too.
Autosave keeps the fields with the rest of the form: a recovered draft brings back the values you typed.
With the editorial workflow
When the editorial workflow is on, each language of the working copy shows the fields too, and so does Add a language. Values are checked the same way when you save the language, and stay in the working copy until a reviewer approves it: the live page keeps its values until then. The comparison with the live version lists each changed field by its key.
Translations
An AI translation of a Page translates its Text and Long text fields with the title and body. Other fields (numbers, dates, choices, yes/no and web addresses) aren't text: a new language starts with the source language's values, and a regenerated one keeps its own. Review them with the rest of the translation before you save.
Site search
Your site's search finds Pages, posts, news and events by their Text and Long text fields too, on the sites each field shows on. Other kinds of field aren't searched.
Show fields on the site
Templates print a field's value with its key, for example content.field("price"). Yes/no fields read "Yes" or "No", and a field without a value prints nothing. Ask whoever maintains your site's templates to place the fields you add.
Change or delete a field
Edit changes everything except the content type and the key. Changing a field's type keeps the values already saved; they're checked the next time each item is saved.
Delete first shows how many language versions hold a value. Confirming deletes the field and removes those values. Revisions saved earlier keep the values they had, and if you later add a field with the same key, restoring such a revision brings its old value back.