Support

Account

Home Forums ACF PRO Page Link in a repeater not working for post type 'product'

Helping

Page Link in a repeater not working for post type 'product'

  • Hey Elliot,

    Another strange one. I can see there has been some kind of clean up in acf_get_post() in api-helpers.php

    I’m not sure when this happened, but any fields that are a page link to a product post type return null.

    If i add unset($args[‘post_type’}) right before $posts = get_posts($args) in acf_get_post() the value returns correctly. I can’t work out a solution as even if i set $args[‘post_type’] = ‘product’ it can’t pick it up.

    Any ideas?

    Nathan

  • I cannot recreate this. From what you say, that unsetting the post_type arg corrects the problem is that
    1) the post type slug was changed, less likely.
    2) that there is some filter or action that is happening to change what’s being returned by get_posts, more likely.

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.