• Hi,

    When using “the_user_favorites_list” filter, is there any way I can return more than just the post title / permalink. I would like to retrieve a custom field within the post which serves as an ID.

    Thanks,

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter Ouadie Lim

    (@ouadielim)

    I found the solution.
    For anyone in the same situation, I used:
    get_user_favorites($user_id = null, $site_id = null, $filters = null);
    which returns an array of the post ids, I then loop through them and use any function that takes in the id (get_field, get_post_meta …)

    Thanks! Could you provide a quick snippet? I’m trying to accomplish the same thing.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Return Custom field (ACF) in list of favorites’ is closed to new replies.