Hello guys, I run into a problem. I use mesmerize theme on a website and I’m unable to change the excerpt. I use a child theme, and I’m unable to remove the filter and replace it with my own style. I tried this general technic but it doesn’t work.
// Replaces the excerpt “Read More” text by a link
function new_excerpt_more($more) {
global $post;
return ’ Lire la suite…’;
}
add_filter(‘excerpt_more’, ‘new_excerpt_more’);
//Remove the excerpt_more filter from mesmerize theme
function child_theme_setup() {
// override parent theme’s ‘more’ text for excerpts
remove_filter(‘excerpt_more’, ‘mesmerize_excerpt_more’);
}
add_action( ‘after_setup_theme’, ‘child_theme_setup’ );