WordPress.org

Ready to get started?Download WordPress

Forums

WP Super Cache
Possible to hide "Rewrite rules must be updated" message on nginx? (4 posts)

  1. Einkoro
    Member
    Posted 2 months ago #

    I have manually setup everything but since its checking for htaccess as if it was apache the message is always displayed in wp-admin. Would it be possible to add an option to hide the message?

    https://wordpress.org/plugins/wp-super-cache/

  2. Pothi
    Member
    Posted 2 months ago #

    Using this one-liner as a mu-plugin... https://github.com/pothi/WordPress-Nginx/blob/master/mu-plugins/nginx-rewrite-compatibility.php removes that message in WPSC. I hope that helps!

  3. Einkoro
    Member
    Posted 2 months ago #

    I'm actually already using that, more or less, although removing the priority didn't make a difference from the one I already had:

    // Remove annoying index.php in permalinks settings with Nginx.
    add_filter( 'got_rewrite', '__return_true', 999 );
    
    // For compatibility with several plugins and nginx HTTPS proxying schemes
    if ( empty( $_SERVER[ 'HTTPS' ] ) || 'off' == $_SERVER[ 'HTTPS' ] ) {
        unset( $_SERVER[ 'HTTPS' ] );
    }

    WPSC still displays the mod rewrite message despite that.

  4. Pothi
    Member
    Posted 2 months ago #

    I could not figure out why that solution doesn't work on your site. Sorry!

Reply

You must log in to post.

About this Plugin

About this Topic

Tags

No tags yet.