I need to replace the existing generated by wp_head() function in header.php with a custom meta description. The informatio
function remove_meta_descriptions($html) {
$pattern = '//i';
$html = preg_replace($pattern, '', $html);
return $html;
}
function clean_meta_descriptions($html) {
ob_start('remove_meta_descriptions');
}
add_action('get_header', 'clean_meta_descriptions', 100);
add_action('wp_footer', function(){ ob_end_flush(); }, 100);