The MU forums have moved to

Cannot Deactivate or Archive Blog in 2.7 (3 posts)

  1. webmaestro
    Posted 15 years ago #

    Since upgrading from 2.6.1 to 2.7, I can no longer Deactivate or Archive Blogs. I get the 'You are about to deactivate the blog [blogname]' and [Confirm] button, followed by the 'Blog deactivated!' notice at the top of the window, but the blog is still active (same for 'archive').

    I thought I was going to have to edit the DB directly:

    wp_blogs SET deleted='1' WHERE wp_blogs.blog_id='[insert-blog-id] LIMIT 1;

    UPDATE: The database shows the archived = 1 and deleted = 1 (so I didn't have to edit the DB), but the blog is still active. I'm using batcache/memcached, but even accessing old posts still works.

    I get nothing in the php-errors or error_log.

    Any ideas?

  2. webmaestro
    Posted 15 years ago #

    It turned out to be a bug in wpmu core. Donncha some updated core code (it'll be fixed in the next WPMU release), and I'm waiting to see if I can post the fix here.

  3. webmaestro
    Posted 15 years ago #

    Here's what worked:

    Here's updated the refresh_blog_details( $id ) function in my /wp-includes/wpmu-functions.php:

    function refresh_blog_details( $id ) {
    $id = (int) $id;
    //$details = get_blog_details( $id, false );
    $details = get_blog_details( $id );
    wp_cache_delete( $id , 'blog-details' );
    wp_cache_delete( md5( $details->domain . $details->path ) , 'blog-lookup' );
    wp_cache_delete( 'current_blog_' . $details->domain, 'site-options' );

About this Topic

  • Started 15 years ago by webmaestro
  • Latest reply from webmaestro