Show page if ACF Repeater has value

21 July, 2022 00:59:26
adtrak
Topics: 4
Messages: 11
I have 3 repeaters one on each page, I want to show the repeater if it has any rows. I'm using a custom shortcode now to output the content to the page which is working really well, thanks for your help on that.

My repeater id is [62] and the page id is 4. I looked at some other posts and thought I had done this right however it either shows the page on both instances where it should only show on one. Can you help?

Thank you
21 July, 2022 01:56:14
E2Pdf
Support
Topics: 7
Messages: 3165
Hi,

Inside "Actions" and "Conditions" must be used shortcodes that are available in E2Pdf Template context.

Is it correct that you have 3 different repeaters and each repeater is placed on different pages, if so you can try to check the first repeater row and if it's empty - "Hide" page.

For example, acf has a shortcode that will output a separate row value:

[acf field='my-row_0_full-name' post_id="[id]"]

* where "my-row" repeater field and "full-name" sub-field. So the "Action" to hide page can look like on screenshot attached.

We remain at your service.

We would really appreciate your feedback at WordPress.org!
21 July, 2022 02:07:10
adtrak
Topics: 4
Messages: 11
That is amazing thank you!