Advertisement
fauzanjeg

Change Latest Article text on 404 Page Not Found

Jul 5th, 2021
149
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.37 KB | None | 0 0
  1. /* Change Latest Article text on 404 Page Not Found */
  2. function jnews_change_latest_articles_text_on_404_page_not_found( $string, $domain, $name) {
  3.     if ( is_404() && $name === 'latest_articles' ) {
  4.         $string = __('Latest Updates');
  5.     }
  6.     return $string;
  7. }
  8. add_filter( 'jnews_return_translation', 'jnews_change_latest_articles_text_on_404_page_not_found', 20, 3 );
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement