Created
November 11, 2013 13:08
-
-
Save keeev/7412937 to your computer and use it in GitHub Desktop.
this is the setting of the actual header.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$seo_title = get_post_meta($post->ID, '_yoast_wpseo_title', true); | |
$seo_title = apply_filters('the_title', $seo_title); | |
if($seo_title == "") $seo_title = get_the_title(); | |
?> | |
<title><?php if (!is_home()) { echo $seo_title; echo " - "; } echo str_replace("%s", "", get_bloginfo('name')); ?><?php # if (!is_home()) | |
echo " "; | |
#get_the_title();#wp_title(); ?></title> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Yoast's SEO hooks into the
wp_title()
function, so all you really need is this:<title><?php wp_title(); ?></title>
as per http://yoast.com/wordpress-seo-plugin-theme-integration-guide/