Title: Custom title issue
Last modified: August 20, 2016

---

# Custom title issue

 *  Resolved [a.s.panchenko](https://wordpress.org/support/users/aspanchenko/)
 * (@aspanchenko)
 * [13 years, 2 months ago](https://wordpress.org/support/topic/custom-title-issue/)
 * Hello. First of all, thanks for your plugin.
 * I have this code to display title of the post/page.
    `<title><?php wp_title('
   |', true, 'right'); bloginfo('name'); ?></title>` And get title like this – **
   Page name | Blogname**, which is what I want. But when I use plugin to change
   title I lost my separators and get: **Custom titleBlogname**.
 * Is this a plugin bug or smth.? Can I make a quick fix?
 * [http://wordpress.org/extend/plugins/add-meta-tags/](http://wordpress.org/extend/plugins/add-meta-tags/)

Viewing 9 replies - 1 through 9 (of 9 total)

 *  Plugin Author [George Notaras](https://wordpress.org/support/users/gnotaras/)
 * (@gnotaras)
 * [13 years, 2 months ago](https://wordpress.org/support/topic/custom-title-issue/#post-3533367)
 * Seems like a bug. Thanks for reporting it.
 * In the upcoming weekend I’ll try to reproduce it using the settings you provided
   and resolve any issues.
 *  [MFan](https://wordpress.org/support/users/mfan/)
 * (@mfan)
 * [13 years, 1 month ago](https://wordpress.org/support/topic/custom-title-issue/#post-3533408)
 * I’m also using your plugin (thanks for it! it’s really great) and was having 
   the same problem. I just fixed it here and I don’t think there’s anything wrong
   with the plugin.
 * In my case, I am using a custom theme based on blankslate. In that theme’s horrifically,
   atrociously, abhorrently formatted functions.php there was this function:
 *     ```
       add_filter('wp_title', 'blankslate_filter_wp_title');
       function blankslate_filter_wp_title($title)
       {
       return $title . esc_attr(get_bloginfo('name'));
       }
       ```
   
 * I just deleted that, and that solved it. So I would suggest searching your theme
   files for “wp_title”, and see if there’s a filter like this. If so, delete it,
   and that should do it.
 *  [tidythemes](https://wordpress.org/support/users/tidythemes/)
 * (@tidythemes)
 * [13 years, 1 month ago](https://wordpress.org/support/topic/custom-title-issue/#post-3533409)
 * **[@mfan](https://wordpress.org/support/users/mfan/)** – Haha, it’s called BlankSlate
   for a reason. There’s nothing wrong with the formatting, because it doesn’t have
   any. It’s semi-minified (as apposed to fully minified where all lines of code
   would be on just one line).
 * The code is like this purposefully and you’ll also see the suppression of programmer
   comments as well. It’s truly the ultimate blank slate boilerplate. You won’t 
   find anything easier out there that allows you to quickly white label and truly
   build your own theme.
 * Open all files in TextWrangler (Mac) or Notepad++ (Win) and do a find and replace
   in all files for the _blankslate_ prefix to replace with your own. Then automate
   the formatting however you like and adjust to your own preferences.
 * We’re not going to impose that onto you. The point of theme is for people to 
   jumpstart their own theme as close to scratch as possible.
 * Thanks and Enjoy
 *  Plugin Author [George Notaras](https://wordpress.org/support/users/gnotaras/)
 * (@gnotaras)
 * [13 years, 1 month ago](https://wordpress.org/support/topic/custom-title-issue/#post-3533410)
 * Thank you all for you feedback.
 * Unfortunately, due to several other obligations, it is impossible to investigate
   whether this is a bug or not at this time. I’ll do some thorough research about
   what might interfere with the title generation/formatting and include any potential
   fixes in the upcoming 2.3.0 release.
 * [@mfan](https://wordpress.org/support/users/mfan/): Thanks for pointing that 
   out.
 *  [zstansfi](https://wordpress.org/support/users/zstansfi/)
 * (@zstansfi)
 * [13 years, 1 month ago](https://wordpress.org/support/topic/custom-title-issue/#post-3533422)
 * I have the exact same problem as panchenko. One thing I noticed is that only 
   _some_ of my posts have the custom title merged to my blog name. Most of the 
   posts have the correct separator | in between.
 *  [Svelte Design](https://wordpress.org/support/users/svelte-design/)
 * (@svelte-design)
 * [12 years, 12 months ago](https://wordpress.org/support/topic/custom-title-issue/#post-3533427)
 * Hi
    As a quick fix to this, I changed the following line of code:
 * $custom_title = str_replace(‘%title%’, $title, $custom_title);
    to $custom_title
   = str_replace(‘%title%’, $title, $custom_title).’ | ‘;
 * Which can be found in add-meta-tags.php on line 1778
 * But please bear in mind that any future updates will overwrite this
 *  Plugin Author [George Notaras](https://wordpress.org/support/users/gnotaras/)
 * (@gnotaras)
 * [12 years, 10 months ago](https://wordpress.org/support/topic/custom-title-issue/#post-3533434)
 * Changed the priority of the ‘amt_custom_title_tag’ filter and now it seems to
   work as expected.
 * Please try setting:
 * `add_filter('wp_title', 'amt_custom_title_tag', 1000);`
 * It will be fixed in v2.3.0.
 *  Plugin Author [George Notaras](https://wordpress.org/support/users/gnotaras/)
 * (@gnotaras)
 * [12 years, 10 months ago](https://wordpress.org/support/topic/custom-title-issue/#post-3533435)
 * According to my tests, setting the priority of the filter high enough (1000) 
   resolves the issue with the unwanted blog name in the custom title.
 * However, if ‘%title%’ is used within the custom title, then the blog name is 
   still appended. The blog name is actually appended to the normal post/page title
   to which ‘%title%’ is expanded. I guess this is a problem of low importance for
   now. Requires further manipulation of the title, which I’ll try to do in another
   plugin release.
 * I’m marking this thread as resolved.
 *  [It’s Thomas!](https://wordpress.org/support/users/itsthomas/)
 * (@itsthomas)
 * [12 years, 2 months ago](https://wordpress.org/support/topic/custom-title-issue/#post-3533447)
 * I have (had) the same problem as posted by a.s.panchenko in the first post of
   this thread with wordpress 3.8.1 and the twenty eleven theme version 1.7.
    Even
   Version 2.4.3 of your plugin didn’t fix the issue for me but following the advice
   from Svelte Design did:
 * > As a quick fix to this, I changed the following line of code:
   > $custom_title = str_replace(‘%title%’, $title, $custom_title);
   >  to $custom_title
   > = str_replace(‘%title%’, $title, $custom_title).’ | ‘;
   > Which can be found in add-meta-tags.php on line 1778
 * Would be great if you could add this fix to your next update.
 * Thanks a lot
 * Thomas
 * PS: Great plugin! Keep up the good work 🙂

Viewing 9 replies - 1 through 9 (of 9 total)

The topic ‘Custom title issue’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/add-meta-tags.svg)
 * [Add Meta Tags](https://wordpress.org/plugins/add-meta-tags/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/add-meta-tags/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/add-meta-tags/)
 * [Active Topics](https://wordpress.org/support/plugin/add-meta-tags/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/add-meta-tags/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/add-meta-tags/reviews/)

## Tags

 * [Meta Tag](https://wordpress.org/support/topic-tag/meta-tag/)
 * [title](https://wordpress.org/support/topic-tag/title/)

 * 9 replies
 * 7 participants
 * Last reply from: [It’s Thomas!](https://wordpress.org/support/users/itsthomas/)
 * Last activity: [12 years, 2 months ago](https://wordpress.org/support/topic/custom-title-issue/#post-3533447)
 * Status: resolved