diff --git a/functions.php b/functions.php index 943911d..61b1818 100644 --- a/functions.php +++ b/functions.php @@ -379,3 +379,21 @@ if (function_exists("pll_register_string")) { pll_register_string('feedback','Submit feedback'); pll_register_string('about_event','about_event'); } + +add_filter( 'wp_title', 'wpdocs_hack_wp_title_for_home' ); + +/** + * Customize the title for the home page, if one is not set. + * + * @param string $title The original title. + * @return string The title to use. + */ +function wpdocs_hack_wp_title_for_home( $title ) +{ + if ( empty( $title ) && ( is_home() || is_front_page() ) ) { + $title = get_bloginfo('name') . ' | ' . get_bloginfo( 'description' ); + } else { + $title = $title . get_bloginfo( 'tagline' ); + } + return $title; +} diff --git a/header.php b/header.php index 18df87c..6c25726 100644 --- a/header.php +++ b/header.php @@ -13,9 +13,9 @@ - + -