[Plugin: Yoast SEO] Problem to remove og tags
-
Hello,
I try to remove and replace this box:
<!-- This site is optimized with the Yoast SEO plugin v2.3.4 - https://yoast.com/wordpress/plugins/seo/ --> <meta name="description" content=" "/> <link rel="canonical" href="https://" /> <meta property="og:locale" content="de_DE" /> <meta property="og:type" content=" " /> <meta property="og:title" content=" " /> <meta property="og:description" content=" " /> <meta property="og:url" content=" " /> <meta property="og:site_name" content=" " /> <!-- / Yoast SEO plugin. -->
Actually, I try it with this code:
function my_title($title,$separator,$position) { if(isset($_GET['article_id'])){ remove_action('wp_head','jetpack_og_tags'); // JetPack if (defined('WPSEO_VERSION')) { // Yoast SEO global $wpseo_front; remove_action('wp_head',array($wpseo_front,'head'),30); } remove_action('wp_head','wpseo_opengraph'); remove_action('wp_head','canonical'); remove_action('wp_head','index_rel_link'); remove_action('wp_head','start_post_rel_link'); remove_action('wp_head','adjacent_posts_rel_link_wp_head'); } return $title; } add_filter('wp_title','my_title',20,3);
I don’t get it…it’s still there. The reason is that I got some dynamic content which isn’t a real site in wordpress, so I like to replace the meta tags.
Thanks!
Bj?rn
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘[Plugin: Yoast SEO] Problem to remove og tags’ is closed to new replies.