Skip to content

picture

lavolpecheprogramma edited this page Oct 24, 2019 · 3 revisions

Picture

{
  "id": "picture",
  "type": "picture",
  "size": "half",
  "label": "label",
  "description": "description",
  "ctaLabel": "Add image",
  "get_sizes": ["thumbnail", "full"],
  "required": true
}

The picture field allows you to input/output an image, selectable with WordPress' stock media picker.

##Options

For the general option fields, check the getting started page.

Custom options

The picture field has an additional option:

  • "ctaLabel" defines the Call To Action for the field's editing mode.
  • "get_sizes" defines the image size that you want to get. The default one is the result of get_intermediate_image_sizes

Filters

You can filter the field's fetched value by calling WordPress' add_filter with the tag "aeria_get_picture".

Clone this wiki locally