WordPress.org

Ready to get started?Download WordPress

Forums

Gallery
[resolved] Permalinks Conflict (3 posts)

  1. In your gllr_custom_permalinks() function you are using $wp_rewrite->flush_rules(); to flush the permalink structure, but you have attached it to the INIT hook. Rewrite rules should never be flushed on INIT, only on activation.

    When you flush rewrite rules on INIT (or many of hooks), you cause the permalinks to be flushed on every page load, and this, aside from causing poor performance, is also extremely prone to creating conflicts with other plugins that register custom post types or taxonomies.

    Please remove the $wp_rewrite->flush_rules(); and instruct users to flush the permalinks themselves or move $wp_rewrite->flush_rules(); to an activation hook instead.

    http://wordpress.org/extend/plugins/gallery-plugin/

  2. Ryan Harne
    Member
    Posted 1 year ago #

    TQ Pippin for the advice.

    I solved my permalink issue by:

    Changed

    -Remove custom permalink action:

    1082: //add_action( 'init', 'gllr_custom_permalinks' );...

    -Add custom permalink: on plugin activation

    28: function gllr_plugin_install(){....
    44: gllr_custom_permalinks();
    45: ..}

    Cheers!

  3. bestwebsoft
    Member
    Plugin Author

    Posted 1 year ago #

    Hello,

    Thanks for the information. We will fix it as soon as possible.

    Best regards,
    OKsana

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic