Tell us what you are trying to do? display sibling of parent through child ID
Is there any documentation that you are following? no
Is there a similar example that we can see? no
What is the link to your site? enlace oculto
the relationships are
one >many: projects>tasks
and
one>many projects>worksample
my view displays all tasks into a table, and displays the parent by pulling @project-task.parent
how do i pull the worksample related to the project?
Hi,
Thank you for contacting us and I'd be happy to assist.
To display "worksample" posts related to a "project" post, you'll need a new post view, with post-relationship filter:
1. Please create a new view and set it to show "worksample" posts.
2. In the "Query Filter" section, you'll add a post-relationship filter for the "projects>worksample" relationship and for the related item source select the option "The post with ID set by the shortcode attribute: wpvrelatedto".
( example screenshot: enlace oculto )
3. You'll need the target "project" post's ID which can be acquired using the item attribute in "wpv-post-id" shortcode:
[wpv-post-id item='@project-task.parent']
4. The last step would be passing this project ID in your newly created view's shortcode, where you'd like to display these related "worksample" posts:
[wpv-view name="view-name" wpvrelatedto="[wpv-post-id item='@project-task.parent']"]
Note: you'll replace "view-name" with this newly created view's name or slug.
I hope this helps and please let me know if you need any further assistance around this.
regards,
Waqar