WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] All CPT permalinks broken after upgrading to 3.2.1 (10 posts)

  1. Parham
    Member
    Posted 2 years ago #

    Hi,

    I had a website running on 3.1.3, and now after upgrading to 3.2.1 all of my CPT permalinks are broken!

    I have 3 custom post types (news, blog and movie) with the following permalink structure (configured with post_type_link and generate_rewrite_rules filters):

    news: /news/%year%/%monthnum%/%postname%
    blog: /blog/%year%/%monthnum%/%postname%

    movie: /movies/%category%/%postname%

    Now every link redirects to the following format which is the default permalink structure (in general settings), and then says 'not found':

    /%year%/%monthnum%/%postname%

    I've tried disabling all of the plugins, but it didn't help.

  2. Parham
    Member
    Posted 2 years ago #

    RESOLVED: It was an issue with the latest version (1.2) of Ultimate Taxonomy Manager Plugin.

    resolved by removing $wp_rewrite->flush_rules(); from ultimate-taxonomy-manager.php

    According to wp docs calling flush_rules() method should be avoided on hooks which execute on each page load, such as init.

    Similar issue with other plugins:
    http://www.zeitblog.com/273/internet-2/word-press-permalinks-broken-fro-category-and-tags-404-error-page-not-found/

  3. eastwoodarts
    Member
    Posted 2 years ago #

    Had this issue also. Basically every time I loaded a page the rules would be rebuilt. The new build would not include custom post type rules (only their taxonomies). Commented out the flush_rules line and rebuilt permalinks by visiting settings->permalinks.

  4. thv20
    Member
    Posted 2 years ago #

    My CPTs URLs are still incorrectly rewritten, even after removing the plugin and flushing permalinks! Any ideas?

    I tried re-installing the plugin and commenting out the above-mentioned line, but the problem persists.

  5. Parham
    Member
    Posted 2 years ago #

    You may have other plugins with the same issue. Search for flush_rules in your plugins codes, or try disabling all of the plugins and then enable them one by one and test. Don't forget to flush your permalinks (by visiting the permalink page) after you enable each plugin.

  6. thv20
    Member
    Posted 2 years ago #

    The CPT-rewrite broke when I added this plugin.
    I disabled *all* plugins and reset permalinks a dozen times — no luck! :(

  7. thv20
    Member
    Posted 2 years ago #

    I should perhaps add that when this plugin is enabled, the single view for my CPTs works but the archive view does not.

  8. thv20
    Member
    Posted 2 years ago #

    Had to do a fresh install, but it works now.
    How do I get access to these new fields? They aren't returned by get_terms.

  9. ljg3
    Member
    Posted 2 years ago #

    Do we know if there are plans to incorporate this patch into the next release? I've had to patch the plugin as well to support CPT permalinks.

  10. XYDAC
    Member
    Posted 2 years ago #

    Sorry for the delay , It will be incorporated in uppcoming version.
    Stay Tuned ..New version coming soon...:)

    regards,
    -Xydac

Topic Closed

This topic has been closed to new replies.

About this Topic