weglot_href_lang
With this filter you can modifiy hreflangs generate by Weglot before we add them.
add_filter( 'weglot_href_lang', 'custom_weglot_href_lang' );
function custom_weglot_href_lang( $render ) {
$render = str_replace( 'hreflang="zh-HK"', 'hreflang="tw"', $render );
return $render;
}Last updated