How to change wordpress post title?
add_filter(‘the_title’, ‘wordpress_title’); function wordpress_title($title){ //Return new title if called inside loop if ( in_the_loop() ) return ‘New title’; //Else return regular return $title; } Have you tried the in_the_loop() conditional check to return new title only if called inside loop. That means nav menu’s will not get affected.