WordPress is a great blogging platform, but it has a bothersome issue of adding the double arrow symbol » before the titles of postings on some templates. The arrow >> is usually used as a special bullet character and the escaped html code is » or 00BB 0020 in hex code.
How to remove the » character from titles:
1. Edit the header.php file of your theme. It can be
found at: wp-content > themes > [YOUR CHOSEN THEME] > header.php
2. Copy this new code:
<title><?php wp_title(‘ ‘); if(wp_title(‘ ‘, false)) { ?> | <?php } bloginfo(‘name’); ?></title>
3. Find the <title> tags in your header.php document (near the top- approx line 7). Select everything between <title> and </title> and paste to replace it with the new code.
After updating, your category pages, archives, tags, and home page should all show the correct title without the ».
Additionally, if you wish to remove the » from the sidebar categories and archives, you may edit the ‘style.css’ file in your theme’s folder, then find and remove the following code:
.entry ul li:before, #sidebar ul ul li:before {
content: "\00BB \0020";
}
Yahoo!
That css double arrows almost cost me my sanity.
Thankyou.
You have NO idea how helpful this was. Thanks so much.
Thank you very much! Who’d have thought double arrows were the default prefix, I searched around for a while trying to find what was putting the arrows in!
Thank you for THE answer!!!! It drive me nuts for hours…
My hats off your solution
You sir, are a genius. Those pesky arrows!
UPDATE: the code above is actually (a common single apostrophe) ‘ instead of `. WordPress theme changed it for some reason.
This code is even better (it doesn’t show the pipe separator on individual pages) [note: again, the ‘ are supposed to normal apostrophes.
<title><?php if (is_home()) {bloginfo(‘name’) ;} else { wp_title(‘ ‘);} ?></title>
Worked for me! Thanks!
youre a legend. this saved my dwindling sanity.
Thank you very much!
The correct code should be:
|
Or Trent Says’ code:
With both of the methods (im currently using: ) you get a few spaces before your title when you go to view source!
Anyone know how to get rid of this?
looks like The article title when you view source
Try viewing the source on this page, you’ll see the open title tag, then a new line, then a few spaces, then the actual title
Another answer is the one provided by the WordPress Default theme. The file header.php uses this, allowing to put what ever you want as separation symbol:
Cheers.
Great little tip, this was pretty annoying and had I built the theme from scratch instead of modifying an existing one I may not have inherited it!
A lesson learned, Thanks!
double arrows were driving me insane your css tip restored my santity! awesome!