wpexpertsio / password-protected

Password protect your WordPress site quickly and simply
https://wordpress.org/plugins/password-protected/
69 stars 63 forks source link

Password Protected not working #96

Open QuentinCloete opened 6 years ago

QuentinCloete commented 6 years ago

Hi Ben

I'm using Password Protected with the Rhythm Wordpress Theme.

The plugin works perfect first time login, asks for password and directs correctly. However, when I login the second time, it opens immediately the content I want protected. I think its a caching issue?

You mention caching problems on certain servers and that 'Password Protected does not always work well with sites that use caching. If your site uses a caching plugin or your web hosting uses server-side caching, you may need to configure your setup to disable caching for the Password Protected cookie: bid_1_password_protected_auth'.

Pls forgive if this comes across stupid: how do know if it's a web hosted server-side caching problem? I've installed WP Super Cache and set it to 'disable caching' on the site but it still login directly to the content I want protected.

Our site is hosted in Norway and we are based in South Africa. Must I ask them to disable caching for the 'bid_1_password_protected_auth'? And how can I disable the specific cookie on our site besides using WP Super Cache, which is obviously not doing the job?

Any advice would be highly appreciated!

Quentin

jdduk commented 4 years ago

was there a solution to this? I'm having the same issue, using siteground as the host. I'm using the autoptimize plugin for caching.

kmnknr commented 4 years ago

Super Cache team has answered this question in https://wordpress.org/support/topic/cache-password-protected-content/. They suggested using basic http authentication instead of a plugin. Technically, if you exclude a specific cookie from caching, once users enter the right password and cookie is saved in their browser, your content no longer is cached with these users and the caching is no mean. Ref: https://blog.litespeedtech.com/2018/01/03/wpw-password-protected-posts/