[wp-hackers] WordPress 3.1 - something strange in the title
lynne.pope at gmail.com
Mon Apr 4 07:54:11 UTC 2011
On Fri, Apr 1, 2011 at 5:45 PM, Jimmy Roy <jimmy.roy at gmail.com> wrote:
> hi all,
> I'm not sure if it's the correct list to ask this question, if I'm not in
> the correct place please tell.
This is really a support question so it should have been asked on the
> I notice something strange in my new WP3.1 installation, for example the
> title of my post is:
> *Vocabulaire - Découvrir les noms - Guide du maître*
> and in the blog the title is transform to:
> *8211; Découvrir les noms - Guide du maître*
> I fix that with this function:
> function cleanWPMess($content)
> $content = str_replace(array("–"), "-", $content);
> return $content;
> add_filter('the_title', 'cleanWPMess');
> add_filter('the_content', 'cleanWPMess');
> add_filter('the_excerpt', 'cleanWPMess');
> but I wonder why WP do that.
WordPress won't do that but something in your theme, plugins, or custom
functions may be the cause.
What WordPress is seeing, for some reason, is " - Découvrir les noms - Guide
du maître" instead of "Vocabulaire - Découvrir les noms - Guide du maître".
Because it is seeing the dash in front of Découvrir les noms it is encoding
it as the HTML entity for a dash. – is the entity that means the same
thing as –
What you need to do is to look at what is stripping out the first word of
your title. The most likely culprit is an SEO function that changes the
More information about the wp-hackers