Shortcode on WordPress meta-title

How to add a shortcode on the meta title bar of WordPress

Very simple to set up.
In the file fonction.php of your themes add these two lines:

add_filter( 'single_post_title', 'do_shortcode' );
add_filter( 'the_title', 'do_shortcode' );

Then you just have to create your shortcode with your favorite editor.

Base, WordPress do not accept shortcodes on the meta-title.
Optimization for search engines, also called natural or organic referencing in French, includes all the techniques that aim to improve the positioning of a page, of a website or web application in a search engine's search results page.

Avec l'utilisation d'un shortcode et d'un plugin SEO comme Yoast SEO, le titre apparait normalement dans l'affichage de votre page mais apparaitra avec le code brut en description méta.
Les variables du modèle de titre ne fonctionneront qu'avec le champ personnalisé pour afficher la valeur des champs de titre SEO ou de méta description.
The solution : this official plugin Do Shortcodes for Yoast SEO to be able to continue without displaying the codes on the referencing.
Be careful to make your shortcodes, SEO is the basis of your website to have visitors.

[site_reviews_summary assigned_to=”post_id”]

[site_reviews_form assign_to=”post_id”]
Rate this article

[site_reviews display=10 assigned_to=”post_id”]

Leave a Reply

Your email address will not be published. Required fields are marked *