Want to subscribe to topics you're interested in?
Become a Member

Wordpress Disable and Enable Super Cache Plugin for Testing Purpose

Discussion in 'Blogs & CMS usage' started by quicksalad, Feb 15, 2016.

  1. quicksalad

    quicksalad Member

    228
    13
    18
    May 31, 2015
    Ratings:
    +20
    Local Time:
    7:18 PM
    How to disable and enable Super Cache plugin to test as some features on theme that I'm currently using are not working.


    Thanks
     
  2. eva2000

    eva2000 Administrator Staff Member

    54,113
    12,179
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,739
    Local Time:
    11:48 PM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    Just disable Wordpress Super Cache plugin from wp admin area and comment out the include file from your nginx vhost by adding hash # in from of the line
    Code:
    # for wordpress super cache plugin
    include /usr/local/nginx/conf/wpincludes/${vhostname}/wpsupercache_${vhostname}.conf;
    and comment out try_files in location context
    Code:
    #try_files /wp-content/cache/supercache/$http_host/$cache_uri/index.html $uri $uri/ /index.php?q=$uri&$args;
    then uncomment (remove hash in front of normal try_files line)
    Code:
      # Wordpress Permalinks
      try_files $uri $uri/ /index.php?q=$uri&$args;  
    then restart nginx and php-fpm
    Code:
    nprestart
     
  3. quicksalad

    quicksalad Member

    228
    13
    18
    May 31, 2015
    Ratings:
    +20
    Local Time:
    7:18 PM
    I'm trying to deactivate first via WP dashboard but I received this prompt below.

    Code:
    One or more files could not be deleted. These files and directories must be made writeable:
    
    /home/nginx/domains/mydomain.com/public/wp-content
    /home/nginx/domains/mydomain.com/public/wp-content/advanced-cache.php
    First try fixing the directory permissions with this command and refresh this page:
    
    chmod 777 /home/nginx/domains/mydomain.com/public/wp-content
    
    If you still see this error, you have to fix the permissions on the files themselves and refresh this page again:
    
    chmod 666 /home/nginx/domains/mydomain.com/public/wp-content/advanced-cache.php
    Don't forgot to fix things later:
    chmod 755 /home/nginx/domains/mydomain.com/public/wp-content
    
    If you don't know what chmod is use this Google search to find out all about it.
    
    Please refresh this page when the permissions have been modified.
    Please advise. Thanks
     
  4. eva2000

    eva2000 Administrator Staff Member

    54,113
    12,179
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,739
    Local Time:
    11:48 PM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    just do as suggested
    Code:
    chmod 777 /home/nginx/domains/mydomain.com/public/wp-content
    disable wp plugin
    then
    Code:
    chmod 755 /home/nginx/domains/mydomain.com/public/wp-content
     
  5. quicksalad

    quicksalad Member

    228
    13
    18
    May 31, 2015
    Ratings:
    +20
    Local Time:
    7:18 PM
    thank you soo much, I just found out that Auto optimize is the one the causes the issue after enabling and disabling some related plugins.