Home Forums ACF PRO Post Object Field Merging Duplicate Titles


Post Object Field Merging Duplicate Titles

  • Hi there! We’re using ACF Pro for everything, and love the heck out of it! Well done, sir.

    One small thing we haven’t been able to sort out is a bug (or feature) with the Post Object field type – it seems to be showing unique post titles, meaning it’s merging duplicates. For instance:

    – We have a CPT for “Product”
    – Two products have the same title, but different specifications
    – We pull this CPT into Post Object and it shows only one of those product titles

    Potential solutions we came up with:
    – Show all posts no matter what (maybe there’s an option for this when creating the field? Slugs are unique, but titles are the same.)
    – Allow the drop-down to include additional data from another field on the posts it’s loading (Product – Spec)

    Is there any way we can tackle either of these solutions with a hook or filter?


  • Hi @machinescott,

    Thanks for the post.

    I would recommend you hook into the acf/fields/post_object/query filter and modify the $args that are used to query the posts on the field type.

    Here is more info on this filter:

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

The topic ‘Post Object Field Merging Duplicate Titles’ is closed to new replies.