Support » Plugin: Yoast SEO » [Plugin: WordPress SEO by Yoast] post_title sanitization for post_name

  • Resolved Igor Yavych


    So I have latest WP and WP SEO and I got some weird problem.
    Since 1.2 “to” is removed from post_title when sanitizing it for post_name field in DB. For example, post title is (without “”) “Lupin III: Mine Fujiko to Iu Onna – Episode 11” so now it produces “lupin-iii-mine-fujiko-iu-onna-episode-11” instead of “lupin-iii-mine-fujiko-to-iu-onna-episode-11” as it is supposed to do and as it was before.
    If this is intended as “deletion of stopwords” or something, is there any way to disable it?
    Also, side question, am I blind, or there is no more option to disable date in snippets? I’m pretty sure I was able to turn it off somehow

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author Joost de Valk


    That is intended behavior and it’s impossible to turn that off right now. Could you tell me why the heck you’d want to turn that off?

    As for dates in snippet previews: it only disabled it in the preview, making people wrongly think it would remove them from their snippets in Google, which the plugin can’t do. That’s why it’s gone. There’s a filter you can use now to have the plugin remove it.

    Oh, I see. Because
    1. I like to have control over my links
    2. I want url to be just sanitized version of title
    3. I wrote plugin for my site that depending on part of post_name of post in certain category does some things. Rewriting it to match newer posts will result in breaking of old ones. For example, if post_name contains lupin-iii-mine-fujiko-to-iu-onna some things done, so if I rewrite to match lupin-iii-mine-fujiko-iu-onna which is only applies to Episode 11, posts with episodes from 01 to 10th will be broken, which is no good.
    So, will adding remove_action for wpseo_remove_stopwords_from_slug or just removing add_action for wpseo_remove_stopwords_from_slug itself properly disable it?
    As for snippets, if it’s not completely removes them but just from preview, I guess there is indeed no real need for that option.

    Plugin Author Joost de Valk


    1.: if you change it manually, the plugin won’t revert it.

    remove_filter will work, yes.

    I misread it. it was indeed add_filter, and not add_action.
    As for reversion, I can do it myself

    Plugin Author Joost de Valk



Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘[Plugin: WordPress SEO by Yoast] post_title sanitization for post_name’ is closed to new replies.