Sauter la navigation

[Résolu] Can a change label for Featured Image (or other CPT labels on backend)

This support ticket is created Il y a 3 années et 7 mois. There's a good chance that you are reading advice that it now obsolete.

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.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 12:00 9:00 – 12:00 9:00 – 12:00 9:00 – 12:00 9:00 – 12:00 -
- 13:00 – 18:00 13:00 – 18:00 13:00 – 18:00 14:00 – 18:00 13:00 – 18:00 -

Supporter timezone: America/Jamaica (GMT-05:00)

Ce sujet contient 4 réponses, a 2 voix.

Dernière mise à jour par peterI Il y a 3 années et 6 mois.

Assisté par: Shane.

Auteur
Publications
#2184841

Hello,

I have a CPT and would like to change the label for "Featured Image" to "Candidate Headshot"
Is this possible within Toolset? Is code needed and is there a resource for snippets.

I thought I would find it in the CPT "Labels" area but Featured Image is not there (as it is in "Additional labels" in the CPT UI plugin). Maybe I'm just missing it.

Thanks for your help.

#2184933

Shane
Supporter

Les langues: Anglais (English )

Fuseau horaire: America/Jamaica (GMT-05:00)

Hi Peter,

Thank you for getting in touch.

I did some checks on this one to see if it was possible and I managed to find the tutorial below.
lien caché

Please try the solution in the link and let me know if it helps.
Thanks,
Shane

#2187941

Just to close the loop on this, that link wasn't helpful for me.
The Toolset user group had a simple, direct answer answer.

function gg_change_featured_image_labels( $labels ) {
$labels->featured_image = 'Headshot';
$labels->set_featured_image = 'Set headshot';
$labels->remove_featured_image = 'Remove headshot';
$labels->use_featured_image = 'Use as headshot';
return $labels;
} // change_featured_image_labels()
add_filter( 'post_type_labels_candidate', 'gg_change_featured_image_labels', 10, 1 );

#2188105

Shane
Supporter

Les langues: Anglais (English )

Fuseau horaire: America/Jamaica (GMT-05:00)

Hi Peter,

Happy that you're able to get a solution to this issue.

What I can do is to add this to the resolved summary for this thread once its marked as resolved.

If there are no further questions then we can go ahead and close here.

Thanks,
Shane

#2188111

My issue is resolved now. Thank you!