Tell us what you are trying to do?
I want to show some fields from a Related CPT in an archives page.
Archives page: hidden link
This archives page contains 3 different CPTs: Dramas, Movies, and Specials
Each CPT may have a "Related CPT of Subtitle Project"
Example of a Drama CPT with a "Related Subtitle Project":
hidden link
Image: hidden link
You can see that there's a special callout box for "Available Subtitles"
I'm able to get the fields to show up from the "Related Subtitle Project" on the "Drama CPT"
Is there any documentation that you are following?
No.
Is there a similar example that we can see?
I'm trying to add the same fields from the "Related Subtitle Project" in the Archives.
I'm using the below code:
Subtitle Status: [types field='overall-status' item="@related-subtitle-project.child"][/types]
[wpv-conditional if="( '[types field='overall-status' output='raw' item="@related-subtitle-project.child"][/types]' eq 'ongoing' ) OR ( '[types field='overall-status' output='raw' item="@related-subtitle-project.child"][/types]' eq 'dropped' )"]
([types field='episode-status' item="@related-subtitle-project.child"][/types])
[/wpv-conditional] by [wpv-post-link item="@related-subtitle-project.child"]
I want it to display this:
Subtitle Status: Status of Subtitle Project by Subtitle Provider's name
Subtitle Status: Announced (linked to Subtitle Project) by amrayu (linked to Subtitle Provider page)
Parts of the site are blocked by Guests. If you need Admin access, please let me know.
What is the link to your site?
hidden link
Hi,
Thank you for contacting us and I'd be happy to assist.
To suggest the best way to achieve this, I'll need to see how these archives and the single post pages are set up, in the admin area.
Can you please share temporary admin login details in reply to this message?
Note: Your next reply will be private and it is recommended to make a complete backup copy, before sharing the access details.
regards,
Waqar
Thank you for sharing these details.
As "Subtitle Projects" post type has a many-to-many post relationship with the post types "Drama", "Movies" etc, you'll need a post view to show the information from the related subtitle post.
On the single drama post page, the website is using a view "Subtitle Projects for Dramas Movies Specials" to show the related subtitles information. You can use the same view in the loop of the archive "Drama Archive" and it will display the related subtitle post information.
If you need to show subtitle information in a different format or with different/selective fields in the archive, you can create a duplicate of the view "Subtitle Projects for Dramas Movies Specials" and use that instead.
My issue is resolved now. Thank you!