If Pods plugin is activated, the WP (all pages) respond with no-cache headers:
Expires: Thu, 19 Nov 1981 08:52:00 GMT
Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
Pragma: no-cache
I try to find in the code some instruction to add headers, but I don't found nothing :(
The installation datas:
Is a wordpress multisite and the pods plugin is activate at network level.
Pods: 2.4.3
WordPress Version: 3.9.1
PHP Version: 5.5.9-1ubuntu4
MySQL Version: 5.5.34
Plugins:
Pods - Custom Content Types and Fields: 2.4.3
Redux Framework: 3.3.2
Some idea?
Thanks!
@gabrielperezs To clarify, are you asking how to add these headers?
No, sorry, my English is not good.
What I mean is: the pods plugin add this headers. If I deactivate the plugin this headers was not there.
@gabrielperezs I'm not sure what in Pods could be causing this. Are you sure that its not something that you are using with Pods, in a Pods Template or Pods Page?
Hi @Shelob9 it麓s me from Pods Forum Template discussion
;) I麓m working with @gabrielperezs and the problem is in the same project.
And yes we are using Pods Template :)
So this means we can not use Pods Template with Varnish cache ?
@Shelob9 we make a test deactivating Pods Template and the problem persist. Also we try to check if was other plugin but not, the headers problem dissapear after deactivate pods :(
Checking some code we found there are code in pods should display options for cache mode but can麓t find any backend UI widget with those options.
Even we try installing Pods Alternative Cache and nothing happends.
Thanx for any help! :)
@Shelob9 finally I found the code who change the headers: https://github.com/pods-framework/pods/blob/7a2d5d16935a27d71c065d6dce6944adc38ef4dd/includes/general.php#L1966
If the Pods plugin is active, and the session is active, the headers is like this:
Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
Content-Type: text/html; charset=UTF-8
Expires: Thu, 19 Nov 1981 08:52:00 GMT
If I set at wp-config.php:
define('PODS_SESSION_AUTO_START',false);
The headers is like this:
Cache-Control: max-age=3600
Expires: Fri, 18 Jul 2014 10:46:53 GMT
:)
So the question is. Pods need session always? is only need for the admin area?
Maybe is possible to start the session like this?
if (!is_admin()) {
@session_cache_limiter('public');
@session_start();
Thanks! :)
Session is actually used in very few cases and we are hoping to phase it out entirely. If setting that constant solves your problem with the headers then I'd just stick with that.
@gabrielperezs I am closing this issue as we have no heard back from you in a while. Please let us know if this is still an issue and we will be happy to help.
Most helpful comment
@Shelob9 finally I found the code who change the headers: https://github.com/pods-framework/pods/blob/7a2d5d16935a27d71c065d6dce6944adc38ef4dd/includes/general.php#L1966
If the Pods plugin is active, and the session is active, the headers is like this:
If I set at wp-config.php:
The headers is like this:
:)
So the question is. Pods need session always? is only need for the admin area?
Maybe is possible to start the session like this?
Thanks! :)