Skip to content

media accessor

Polmonite edited this page Sep 21, 2019 · 1 revision

MediaAccessor

The media accessor retrieves media related to the post.

Syntax:

The media accessor retrieves media related to the post.

Syntax:

@media:{size},{media_meta_key_or_id}

  • {size}: media size (full, thumbnail, etc.; custom sizes are accepted as long as they have been registered);
  • {media_meta_key_or_id}: if the id of the wanted media is saved inside a post meta, we can specify here the wanted meta key; if we know directly the id of the media, we can pass that; media_meta_key_or_id is specified, the post thumbnail is used.

Examples:

Other

Extend Malini

  • Create your own Accessor
  • Create your own Decorator
  • Available Extensions
    • Malini\Aeria
    • Malini\YOAST
    • Malini\ACF
Clone this wiki locally