Need to Remove Meta Description Generator
-
Hi there, I noticed the plugin is auto-generating a meta description for my articles. How do I remove this feature? It’s creating multiple metas for my articles.
Thank you!
-
Thanks for reaching out @isabelle09876, and great question regarding the meta tag. You can remove this tag by adding the below to a custom PHP snippets plugin or a child themes functions.php file:
remove_action( 'wp_head', 'perflab_render_generator' );
If you need assistance with this, let me know. I can place the above in a mini plugin if preferred, just let me know. Thank you!
Thanks so much for your reply! Actually, we saw that same code in this other thread and had tried that as well but it didn’t work.
Do you have any other suggestions?
@isabelle09876 Sorry to hear that. Where are you adding the code? Let me know, as I can place share this in the form of a mini plugin if needed.
We put the code in the function.php file – and no change. We’d be open to testing a mini plugin. 🙂 Thank you.
Question: Why do the generator meta tags need to be removed? They really help us out to measure the impact of the performance improvements across WordPress sites.
I’m getting double meta tags because Yoast also generates them automatically.
Double meta tags but not duplicate, right? You can have any number of meta generator tags on the page. A few popular plugins that add their own generator tags: Elementor, WooCommerce, and SiteKit by Google.
Hi again, yes multiple meta description tags and yes, duplicate. Any ideas on how to remove these auto-generators?
Please share the URL where this issue can be observed.
Hi there, thanks for all your help but our developer managed to find a way to fix this. 🙂
I’ll just note that, again, preserving our meta tags on the page is very helpful for us to track the performance impact of our plugins in HTTP Archive.
Or complete solution for all additional modules:
add_action('init', static function() {
remove_action( 'wp_head', 'perflab_render_generator' );
remove_action( 'wp_head', 'image_prioritizer_render_generator_meta_tag' );
remove_action( 'wp_head', 'plsr_render_generator_meta_tag' );
remove_action( 'wp_head', 'auto_sizes_render_generator' );
remove_action( 'wp_head', 'dominant_color_render_generator' );
remove_action( 'wp_head', 'embed_optimizer_render_generator' );
remove_action( 'wp_head', 'webp_uploads_render_generator' );
remove_action( 'wp_head', 'od_render_generator_meta_tag' );
if ( class_exists( 'Performant_Translations' ) ) {
remove_action( 'wp_head', [ Performant_Translations::class, 'add_generator_tag' ] );
}
}, 15);-
This reply was modified 6 months ago by
davidulus.
Again, preserving our meta tags on the page is very helpful for us to track the performance impact of our plugins in HTTP Archive. Without this information, it is difficult to know whether we should move forward with merging the performance features into WordPress core. So please don’t do this.
Thank you for your recommendation, I really appreciate it.
Here is the updated code that includes the Image Prioritizer plugin and the new Web Worker Offloading:add_action( 'init', static function() { remove_action( 'wp_head', 'perflab_render_generator' ); remove_action( 'wp_head', 'image_prioritizer_render_generator_meta_tag' ); remove_action( 'wp_head', 'plsr_render_generator_meta_tag' ); remove_action( 'wp_head', 'auto_sizes_render_generator' ); remove_action( 'wp_head', 'dominant_color_render_generator' ); remove_action( 'wp_head', 'embed_optimizer_render_generator' ); remove_action( 'wp_head', 'webp_uploads_render_generator' ); remove_action( 'wp_head', 'od_render_generator_meta_tag' ); remove_action( 'wp_head', 'plwwo_render_generator_meta_tag' ); add_action( 'od_init', static function() { remove_action( 'wp_head', 'image_prioritizer_render_generator_meta_tag' ); } ); if ( class_exists( 'Performant_Translations' ) ) { remove_action( 'wp_head', [ Performant_Translations::class, 'add_generator_tag' ] ); } }, 15 );
-
This reply was modified 6 months ago by
- You must be logged in to reply to this topic.