• Hi,
    I’m working with the WPML plugin and we’ve some duplicated pages. These pages show the primairy language (English) in the alternative laguages.
    The WordPress SEO plugin adds a canonical link in the head section, for example:
    <link rel=”canonical” href=”https://whatever/mypage/&#8221; /> on the English page and that is fine.
    But on a German page (which is a duplicate) for example it generates:
    <link rel=”canonical” href=”https://whatever/de/mypage/&#8221; />
    And that is not correct. It should refer to the primary language:
    <link rel=”canonical” href=”https://whatever/mypage/&#8221; />
    In this case i’m getting duplicated content.
    Is there a way to remove that canonical link that is generated by the SEO plugin? I have used: add_filter( ‘wpseo_canonical’, ‘__return_false’ ); but this removes all the canonical links, also the one that WPML provides.

    https://www.ads-software.com/plugins/wordpress-seo/

  • The topic ‘Canonical link and WPML’ is closed to new replies.