Notifications
Clear all

Remove og:locale from wpforo seo?

2 Posts
2 Users
1 Reactions
196 Views
Posts: 16
Topic starter
(@spielo)
Eminent Member
Joined: 2 years ago

i have to remove the tag <meta property="og:locale" content="de_DE"> from seo, how can i do this?

1 Reply
Sofy
Posts: 4900
 Sofy
Admin
(@sofy)
Support Team
Joined: 7 years ago

Hi, 

Use this hook-code: 

add_filter( 'wpforo_seo_meta_tags', function(string $metas){ return preg_replace( '#<meta\sproperty="og:locale"\scontent="de_DE"[\s/]*>#iu', '', $metas ); } );

You should insert it in the active theme functions.php file.

This article should be helpful for you:  https://www.wpbeginner.com/plugins/how-to-easily-add-custom-code-in-wordpress-without-breaking-your-site/

Reply