Home Forums WC Vendors Free Support Vendor tab – product page Reply To: Vendor tab – product page

#59652
Derek Smith
Participant

Hi Narked,

Not sure if this is what you’re after but I needed to replace “Vendor” with “Author” throughout a site. I’ve added an !is_admin here so it doesn’t affect the backend, but I suppose you could alter that to any other conditional.

function translate_mtpt($translated) {
	$translated = str_ireplace('a Vendor', 'an Author', $translated);
	$translated = str_ireplace('Vendor', 'Author', $translated);
	return $translated;
}
if (!is_admin()) {
	add_filter('gettext', 'translate_mtpt');
	add_filter('ngettext', 'translate_mtpt');
}
This website uses cookies to ensure you get the best experience on our website.