Skip Navigation

[Résolu] Displaying Parent title isn’t working

Ce fil est résolu. Voici une description du problème et la solution proposée.

Problem:

The issue here is that the user wanted to display the parent title of their post

Solution: When using the fields and views button to add the shortcode to the page, it should give you the option to select the post that you want to display the title for. This includes the Parent CPT. See Screenshot

If you select "Post Selection" and then "A post related to the current post, set by a Types relationship" then you should be able to select your parent CPT to display its title.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Our next available supporter will start replying to tickets in about 4.99 hours from now. Thank you for your understanding.

This topic contains 3 réponses, has 3 voix.

Last updated by rodolfod Il y a 3 années.

Assigned support staff: Shane.

Auteur
Publications
#1094018
Screen Shot 2018-08-28 at 10.50.16 AM.jpg
Screen Shot 2018-08-28 at 10.49.22 AM.jpg

I am trying to: display the title of the parent cpt

Link to a page where the issue can be seen: hidden link

I expected to see: The Author's name (the Author is a "Team Member" CPT where the name is the CPT title)

Instead, I got: The title of the current post

The Team Member CPT slug is "team-member" and I inserted the shortcode into the Post Template as follows: [wpv-post-title id="$team-member"], which is how I've done this in the past but it's not working for some reason. I'm sure I'm missing something simple or obvious, but I haven't been able to figure out why it's not working.

Thanks for the help.

#1094106

Shane
Supporter

Languages: Anglais (English )

Timezone: America/Jamaica (GMT-05:00)

Screen Shot 2018-08-28 at 4.18.20 PM.png

Hi Josh,

Thank you for contacting our support forum.

When using the fields and views button to add the shortcode to the page, it should give you the option to select the post that you want to display the title for. This includes the Parent CPT. See Screenshot

If you select "Post Selection" and then "A post related to the current post, set by a Types relationship" then you should be able to select your parent CPT to display its title.

Please let me know if this helps.
Thanks,
Shane

#1094126

Ahh perfect. I like this built-in approach, that's a nice improvement.

Thanks for the help Shane.

#1143847

Hei shane, can you also answer the mmio ticket? or are you too busy with anything else?