• As in the title. When permalinks are set as default AIOSEP canonical urls are broken (they return url to non-existent 404 page).

    The problem is that your code doesn’t take this into consideration (default permalink structure). This should be checked inside your get_paged function. One of the options is

    if(!empty( $wp_rewrite ) && !$wp_rewrite->using_permalinks()) {
    return add_query_arg(‘paged’, $page, $link);
    }

    https://wordpress.org/plugins/all-in-one-seo-pack/

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Support Steve M

    (@wpsmort)

    The plugin works fine with the default permalink structure, I’ve witnessed this on many sites. However, there’s no reason to use an SEO plugin on a site that uses the default permalink structure because the default permalink structure is bad for SEO and many features of All in One SEO Pack won’t work with the default permalink structure.

    Thread Starter Arkadiusz Rzadkowolski

    (@fliespl)

    @wpsmort: Some example:

    http://wp-test.dige.com.pl/?cat=1&paged=2
    generates:
    <link rel=”canonical” href=”http://wp-test.dige.com.pl/?cat=1/page/2&#8243; />
    which is 404

    Plugin Support Steve M

    (@wpsmort)

    This is a great example why you do not want to use the default permalink structure. If you care about SEO then don’t use it.

    Thread Starter Arkadiusz Rzadkowolski

    (@fliespl)

    @wpsmort: With all due respect – It’s not a discussion regarding if I should use permalink structure or not – it is about a bug in the functionality.

    Yes, for me it’s a bug unless it’s stated in the description that “this plugin doesn’t work correctly with default permalink structure”.

    BTW. Don’t you think it’s worth checking out? As there were other tickets to this issue in the past. I have even taken time to investigate and proposed a fix for you.

    Plugin Support Steve M

    (@wpsmort)

    I tested this on one of my sites and it works for me. As I said in my original reply, I’ve seen plenty of sites that use the default permalink structure and never seen any issues with canonical URLs although I would not expect canonical URLs to work with the default permalink structure. Canonical URLs are designed to work with pretty permalinks.

    Let me be clear, we do not support canonical URLs with the default permalink structure.

    Thread Starter Arkadiusz Rzadkowolski

    (@fliespl)

    Thank you very much. I appreciate you reply. Have a nice day!

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Canonical URLs broken when permalink structure set to default’ is closed to new replies.