• Resolved Mary Linville

    (@sunshine)


    I posted about this before, but didn’t get anywhere (going on a month since). I cannot seem to be able to add to, modify or remove permalinks via the plugin API (specifically, WP_Rewrite).

    Here is an extreme example, for the purpose of illustration, which I’ve placed in my active theme’s functions.php file (doesn’t work as a plugin either):

    function customize_permalinks($rules)
    {
    return array();
    }

    add_filter('rewrite_rules_array', 'customize_permalinks');

    That should remove all permalinks, correct? Well, it doesn’t, a print_r() of $wp_rewrite->rules shows that they are all still there, and they all still work.

    What’s wrong?

Viewing 1 replies (of 1 total)
  • Thread Starter Mary Linville

    (@sunshine)

    Okay, I have also tried using both the Ultimate Tag Warrior and Feed Director plugins, and both do not work, the urls that is – trying to view the urls supported causes 404s.

    Regular clean permalinks (pages, posts, categories, etc) work fine, but not permalinks added through the plugin api. So I now know it’s not just my attempt.

    Any ideas what’s the deal here?

Viewing 1 replies (of 1 total)
  • The topic ‘Plugin API: WP_Rewrite, implementation help needed’ is closed to new replies.