Hi I got a 405 error on all cached form pages that want to send data via post. So once I fill data in the cached page and want to send it I get the 405 not allowed. With easy engine and Nginx-rocket setup I did not have that problem in the past. Any ideas what can be done, change some Nginx config?

Found this with same issue: https://www.bountysource.com/issues/80156820-after-ee-to-wo-migration-existing-multisite-site-update-domain-com-wpsubdom-wprocket

I now switched to redis for the moment, as with that WP Rocket config issue my guest can not apply to jobs or publish jobs once the pages have been cached earlier. Other option would be to use https://github.com/SatelliteWP/rocket-nginx instead. Maybe you have some ideas because I guess many WP Rocket users with forms to publish content may run into the same issue.

So after having issues with caching my front page with redis-full-page-caching option -wpredis (otherwise its really great), I went on and setup the https://github.com/SatelliteWP/rocket-nginx. Just go by the setup description on the website and then change your Nginx site configurations as follow:

sudo nano /etc/nginx/sites-available/yourwebsite.com

Having had the wpredis setup config I changed the include part as following:
(uncomment the redis configuration or what ever other caching configuration you setup your initial website e.g. include common/wprocket-php73.conf)

# include common/redis-php73.conf;
#add the php7x.conf instead, please use the right php version in my case php73 and add the rocket-nginx/default.conf
include common/php73.conf;
include rocket-nginx/default.conf;
include common/wpcommon-php73.conf;
include common/locations-wo.conf;
include /var/www/sportyjob.com/conf/nginx/*.conf;

Thats it, works like it should so far and no more Error 405. Maybe you should consider using the https://github.com/SatelliteWP/rocket-nginx for WP-Rocket setup in Wordops for the future.

    Hello Lens,
    we are already working on improving our Nginx configuration for WP-Rocket, a new configuration should be available in the next releases.

      VirtuBox Great, what is your comment on WP-Rocket and Wp-redis please?

      which one is for better performance please?

      Thanks

      • Lens replied to this.

        VirtuBox Great, thanks. I guess you do not reinvent the wheel, so you might get in touche with Benjamin from rocket-nginx and use his configuration. Works great.

        alexlii1971 Guess there is no difference, once the page is cached the PHP is bypassed and a HTML is severed so I guess that there is no real difference. But I have not benchmarked it. So if you do not use WP Rocket redis might be just fine. With WP Rocket you have a few more options of handling your cache, when to clean it, what to clean at what point etc. With redis the Nginx-Helper-Plugin is a bit more limited even though I guess you might be able to add some code to achieve what you want.

          Hello Lens

          Thanks for reply.

          Actually, I did not touched wp Rocket before, as for as I know it is a paid plugin, and did not find an free version when I searched on Wordpress.

          it would be great if like share a screenshot of Wp-rocket here.

          Thanks

          4 months later

          Thanks to @Lens for creating this topic, otherwise I wouldn't have figured it out. This is a serious issue with WordOps's default WP Rocket configuration that it doesn't work well with WoCommerce installations.

          There is no issue for the logged in users but suppose a Guest is browsing the site and he clicks "Add to Cart", the page will display 405 not allowed error page.

          As mentioned by OP, the workaround is using Satellite NGINX Configuration which is pretty easy to do. I hope the master @VirtuBox will do the needful in the upcoming update 🙂

            12 days later

            nsgoyat
            hello friend how are you an inquiry
            open correct this error 405
            I am with this same problem without being able to solve it
            if you have any help like getting out of this problem it is appreciated.

            6 days later

            nsgoyat There is no issue for the logged in users but suppose a Guest is browsing the site and he clicks "Add to Cart", the page will display 405 not allowed error page.

            So, Wp-rocket is not compatible with Woocommerce please?

            Thanks

              alexlii1971 WordOps's --wprocket configuration isn't compatible with Woocommerce.

              5 months later

              Also just had a 405 issue with a site using WP Rocket - but NOT a WooCommerce issue, this was giving a 405 error and blocking logging in to the WP Admin area (login page loads but 405 on submitting).
              This was also resolved using the Rocket Nginx config as above. The site was using a hidden login page so I suspect that may have been the issue, as this config bypasses caching for all Post requests. Not digging in to it further as we'll probably ditch WP Rocket anyway.

              8 months later
              22 days later

              How is this still an issue? This seems like a major, major bug.

                bennettwebgroup WordOps hasn't received any major updates for more than a year. The leader developer @VirtuBox is unable to get some free time for the project.

                For the time being, you can use Rocket NGINX Configuration as mentioned by the OP.

                3 years later

                Well my friends... After 4.5 years, the issue still persists!

                I'm using --wprocket along with Perfmatters with changing login URL to something else, so it's not the normal wp-admin login URL. After i hit LOGIN button, the 405 Not Allowed appeared.

                I know i just can use the Satellite Nginx config, but yeah, i just need to tell the devs that the problem still exist till now. Thanks.

                405 Not Allowed

                  Hosted by VirtuBox