Expires On

Free!
Download
Expires On
Description

A Statamic 2.0 modifier for tag pairs that cannot be filtered with conditions (aka not a collection or taxonomy). The expiration date field is specified as a parameter (expiration_date in the example below), and it returns items that either don't have one, or have one which is in the future.

Copy ExpiresOn folder into /site/addons/.

Usage

Assuming Today is 2018-1-26

YAML

blocks:
  - 
    block_title: Block A
    expiration_date: 2018-02-28
  - 
    block_title: Block B
    expiration_date: 2017-04-13
  - 
    block_title: Block C
  - 
    block_title: Block D

Antlers

{{ blocks expires_on="expiration_date" }}
  {{ block_title }}<br>
{{ /blocks }}

Outputs

Block A
Block C
Block D

Important Links
Details
Released March 19, 2018
Updated 2 years ago
Version dev-master
Downloads 525
Requires Statamic 2

Becky Soll

More by Becky Soll

Similar Addons

See All
A tag pair to turn those replicator and bard sets into friendly neighbors, able to retrieve the type (or other field) from the next or previous set. Hidey ho!

Neighbors

by Becky Soll in Modifier
A tag pair to turn those replicator and bard sets into friendly neighbors, able to retrieve the type (or other field) from the next or previous set. Hidey ho!
Typeahead search for FontAwesome icons in the CP and easily output icons in templates using tags.

FontAwesome

by Aryeh Raber in Modifier
Typeahead search for FontAwesome icons in the CP and easily output icons in templates using tags.
Modifier that converts formatted phone numbers into valid href "tel" strings.

Tel

by Aryeh Raber in Modifier
Modifier that converts formatted phone numbers into valid href "tel" strings.
Searches occurences of files and replaces them as listed in the manifest

AssetManifest

by Mintel.me in Modifier
Searches occurences of files and replaces them as listed in the manifest