Support

Account

Home Forums Backend Issues (wp-admin) Get posts related to ACF User field(Author)

Unread

Get posts related to ACF User field(Author)

  • Hi,
    I have added ACF User field(Author field) inside the post where we can select multiple authors of the post. When I query(wpgraphql) this user field to get related posts of that author it is showing null, because it is using default author of the wordpress and not from the acf user field.
    The query I’m using for the acf user field is:

    users(where: {role: AUTHOR}) {
        nodes {
          name
          posts {
            nodes {
              title
            }
          }
        }
      }

    Is there any way we can use ACF user(author) field for querying out the related post?

Viewing 1 post (of 1 total)

You must be logged in to reply to this topic.