Support

Account

Home Forums Gutenberg ACF 5.8 – Parse Gutenberg blocks and get ACF data outside of post Reply To: ACF 5.8 – Parse Gutenberg blocks and get ACF data outside of post

  • Hi, I think @matthewfarlymn ‘s solution is what I am needing, but I am not 100% on how to make it work for what I need.
    I have a CPT – Events with two taxonomies (event_category) – upcoming & past events.
    I am trying to have them listed in order of the event date.
    For upcoming events, the one happening soonest first – to the furthest away.
    And for past, then the most recent first. Etc..
    The thing is, the event date is entered in the post via an ACF field within a block in each post.
    My current template only shows the posts if I remove or comment out the
    'meta_key' => array( $date ),
    Template File: GIST

    How can I use the solution above, and integrate it with the template?
    I tried dropping it into functions.php, but got an error (had edited to include block name & field).
    Any guidance would be greatly appreciated.