Hello,
Thank you for contacting us and sorry for any inconvenience that might have been caused due to that.
You can edit the following filter to your specifications to achieve a similar result:
add_filter( 'rank_math/json_ld', function( $data, $jsonld ) {
if( in_category( 1 ) ) { // Change this to the category ID that you want to change
$data['WebSite']['inLanguage'] = 'de-DE';
$data['WebPage']['inLanguage'] = 'de-DE';
}
return $data;
}, 99, 2);
Hope this helps solve your issues.
Don’t hesitate to get in touch if you have any other questions.
Hello Miguel,
thanks for your answer, I got the same issue with the “Organization” markup. What is your recommandation on that in order to change it for another country tag?
"inLanguage": "en-US",
Have a nice day
Thank you for your answer. I solved the problem by adding class-jsonld.php to this
Hello,
Glad that helped and thank you for sharing the code.
Please feel free to reach out to us again in case you need any other assistance.
We are here to help.
Thank you.