Viewing 5 replies - 1 through 5 (of 5 total)
  • Michael Torbert

    (@hallsofmontezuma)

    WordPress Virtuoso

    For the moment, you can correct it with these steps:
    Open up functions.php of your TwentyTen theme and go to line 262.
    You’ll see a line that looks like

    add_filter( 'wp_title', 'twentyten_filter_wp_title', 10, 2 );

    Just add two forward slashes in front of it so that it looks like

    //add_filter( 'wp_title', 'twentyten_filter_wp_title', 10, 2 );

    We’re working on hopefully fixing TwentyTen so that it doesn’t have this issue.

    I was having the same problem and commenting the line out worked for me.

    Cheers,
    Robert

    hi folks, i have the same problem but i’m not using the Twnetyten theme actually, i use another theme and in the functions.php of the theme i didn’t fidn that “add_filter( ‘wp_title’)”.

    What i can do to solve this problem?

    By commenting out the line, it kind of defeats the purpose of providing a template structure for the parent of a child theme framework. I had the same issue, and I added the following code to my child theme’s functions.php file.

    add_action( 'after_setup_theme', 'hmw_fix_twentyten_titles' );
    function hmw_fix_twentyten_titles () {
    	remove_filter( 'wp_title', 'twentyten_filter_wp_title');
    }

    This will run after the filter is added in twentyten’s functions.php, but still in time to remove the filter itself.

    Ultimately, it would be best for twentyten to change the code and either (a) make a flag/define on whether to use their built-in “SEO” or (b) make the ‘twentyten_filter_wp_title’ pluggable. The latter seems like the better option for a child theme framework.

    Maybe in a future version they will wrap the function with:

    if ( ! function_exists( 'twentyten_filter_wp_title' ) ) :
    
    ...CURRENT CODE GOES HERE...
    
    endif;

    Joe

    Hi guys,

    Just a heads up for those using the ‘Starkers’ theme as your foundation:

    The filter you need to comment out appears at ~226, not 262 like in TwentyTen.

    add_filter( 'wp_title', 'twentyten_filter_wp_title', 10, 2 );

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘[Plugin: All in One SEO Pack] Post title incorrect with AIOSEOP 1.6.11’ is closed to new replies.