Field Datatypes

This article covers Field Datatypes. Each field is defined by its datatype, and some datatypes are more specialized than others. For example, the Date field datatype only takes a date in the form of YYYY-MM-DD. Fields are the interface through which you'll be adding content to your pages, pagesets and datasets. Please see a list of all our field datatypes and their descriptions listed below.

Datatypes

  • Article Writer
    • Description: This is a field that you can type in and add images to. You can drag and drop images into the field, and when you highlight text that you've already typed a box pops up with simple formatting options such as bold, italic, blockquote, and more.
    • Plate Syntax: <article_writer name="articlewriter_field" name_friendly="Article Writer Field" />
  • Brandisty Logo
    • Description: This field allows you to upload a logo from Brandisty. Please note, to use this field a Brandisty account is required.
    • Plate Syntax: <brandisty name="brandisty_field" name_friendly="Brandisty Field" />
  • Color
    • Description: This is a field where you can enter color values such as '#ffffff' or 'blue'. It has a limit of 150 characters. It currently does not validate the hex code or have a color picker.
    • Plate Syntax:<color name="color_field" name_friendly="color_field" />
  • Currency
    • Description: This is a field where you can enter a dollar sign ($), numbers, and up to 2 decimal points. For example: $15.99. It has a limit of 150 characters.
    • Plate Syntax: <currency name="currency_field" name_friendly="Currency Field" />
  • Date
    • Description: This is a field where you can select a date from a pop-up calendar, you cannot type a date into the field, it must be selected from the calendar. The date is string-formatted as YYYY-MM-DD. To apply date formatting use ".date()" call and include PHP data format characters.
    • Plate Syntax: <date name="date_field" name_friendly="Date Field" />
  • DateTime
    • Description: This is a field where you can select a date from a pop-up calendar. After you've selected a date from the calendar, a time pop-up allows you to select a time from a 24-hour digital clock. The DateTime is string formatted YYYY-MM-DD HH-MM-SS. To apply date formating use ".date()" call and include PHP data format characters.
    • Plate Syntax: <datetime name="datetime_field" name_friendly="Datetime Field" />
  • Dropdown
    • Description: This field creates a dropdown with different options made up of key:value pairs.
    • Plate Syntax: <dropdown name="default_fields" name_friendly="Default Form Fields" options="no_form:No Form;basic_form:Patient Basic Form;adv_form:Patient Advanced Form;" />
  • Files
    • Description: This is a field where you can click a button to upload a file from the media bin.
    • Plate Syntax: <files name="files_field" name_friendly="Files Field" />
  • Font Awesome
    • Description: This is a text field for the name of a font-awesome icon. Field uses the name of the icon only. For example, if you wanted an icon for Facebook, you would type 'facebook' (no quotes) in the text field, instead of the 'fa fa-facebook' syntax. Font Awesome Icon List
    • Printout Notes: Prints out exact characters represented in the backend. To use with "fa" syntax, use "substring(4,100)" to strip "icon" from the icon name.
    • Plate Syntax: <fontawesome name="fontawesome_field" name_friendly="Font Awesome Icon" />
  • Images
    • Description: This creates a field for inserting an image from the Media Bin. The number of images can be limited by using the 'limit' parameter in your image tag. Note that when calling the field in your view, you must use the getImage() Parsley call to access the file URL, if not the file's CDN ID number will print out on the page.
    • Plate Syntax: <images name="main_image" name_friendly="Main Image" limit="1" />
  • Internal Link
    • Description: This field creates a dropdown with all available internal links. The dropdown will have all the pages on the site, sorted alphabetically by Navigation title. In the View what prints out is the ZID associated with the selected page. Use the Parsley call truepath() to access the page URL.
    • Plate Syntax: <internal_link name="btn_links_to" name_friendly="Button Links To" />
  • Link
    • Description: This creates a text field for a link which requires the form of a URL, e.g., http:// or https://. It has a maximum character limit of 150 characters.
    • Plate Syntax: <link name="link_field" name_friendly="Link Field" />
  • Markdown
    • Description: This field creates an open text area that accepts markdown syntax and formatting.
    • Plate Syntax: <markdown name="markdown_field" name_friendly="Markdown Field"/>
  • Number
    • Description: This creates a field for numbers (with optional decimal point), with a max input of 150 characters. Commas or currency signs are not allowed.
    • Plate Syntax: <number name="number_field" name_friendly="Number Field" />
  • One to Many
    • Description: This field allows users to create one-to-many relationship between a page and a dataset, a pageset and a dataset, or a dataset and a dataset.
    • Plate Syntax: <one_to_many name="additional_fields" name_friendly="Additional Form Fields" relationship="custom_form_fields" relationship_field="custom_field_name" />
  • One to One
    • Description: This field allows users to create one-to-one relationship between a page and a dataset, a pageset and a dataset, or a dataset and a dataset.
    • Plate Syntax: <one_to_one name="employee_category" name_friendly="Employee Category" relationship="employee_category" relationship_field="employee_category" list="1" />
  • Sort
    • Description: This creates a unique field to allow for a numerical sorting of pagesets and datasets. You can change the default sort number with the plus and minus buttons in the pageset or dataset, as well as in the table view.
    • Plate Syntax: <sort name="sort_order" name_friendly="Sort Order" />
  • Text
    • Description: This field creates a text field limited to 150 characters.
    • Plate Syntax: <text name="homepage_title" name_friendly="Homepage Title" />
  • Textarea
    • Description: This creates an open text area with an unlimited character count. The bottom right corner is draggable for resizing. Line breaks print out as
      tags unless you add '_raw' to the end of the field name in the Parsley call.
    • Plate Syntax: <textarea name="bubble_blurb" name_friendly="Bubble Blurb" list="1" />
  • WYSIWG Advanced
    • Description: This creates a 'What You See Is What You Get' (WYSIWYG) text field, i.e., all formatting that you have, such as bolded text, font size, italics, etc. will be exactly what you see on your site. Note, there is currently no difference between the advanced and basic WYSIWYG.
    • Plate Syntax: <wysiwyg_advanced name="image_caption" name_friendly="Image Caption" />
  • WYSIWG Basic
    • Description: This creates a 'What You See Is What You Get' (WYSIWYG) text field, i.e., all formatting that you have, such as bolded text, font size, italics, etc. will be exactly what you see on your site. Since there is currently no difference between the advanced and basic WYSIWYG, we recommend using WYSIWYG Advanced.
  • Yes / No
    • Description: This creates a customized toggle field made up of key:value pairs. The key will either be 0 (zero) or 1 (one), however the value is customizable. Since the key is either 0 or 1, the logic for if-statements or where-statements will take the form of {{ if {this == 0} }}.
    • Plate Syntax: <yes_no name="field_type_toggle" name_friendly="Field Type (text: 150 character limit; textarea: unlimited)" options="0:Text;1:Textarea;" list="1"/>

Adding a Field

Adding a field is done inside the specific set you would like to configure. Start by navigating to the desired set underneath the Content Configurator.

Untitled

Select the set you want to edit from the left hand list of all your available sets.

Untitled

Click the "Add New Field" button to reveal the field setup interface.

Untitled

Display Name: This is the description you want to be shown to your users who will be adding content.

Reference Name: This is the name you will use in Parsley to reference an instance of this field.

Finalize the field by clicking "Add to Set"

Removing a Field

After a field has been created it can be removed by returning to the set inside the Content Configurator. Click the field you wanted removed and a red "Remove" button will appear. Removing a field permanently deletes it and any content associated with it.

Untitled