Posts: 8
Threads: 2
Joined: Feb 2015
2015-03-16, 12:59:12
(This post was last modified: 2015-03-16, 13:06:34 by gessler.)
Hi, I got a problem with some contact forms in general, these four create a session header(token)
GetSimple Contact
Simple C(ontact)
Contact Form
p01-contact.
After activating one of these (tested each one after another) I got this when testing the HTTP Header:
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
No client cache at all at the entire website,
Is this really the expected behavior? Another stupid queston, is there a way to turn on off a plugin on page or template base?
Thanks to anyone in advance
Posts: 6,266
Threads: 181
Joined: Sep 2011
When using sessions, php will send these.
i18n_base uses session_start, as do other plugins.
you might be able to set before, but I am not really sure what the complete effect will be.
session_cache_limiter(false);
Posts: 8
Threads: 2
Joined: Feb 2015
Thank you, that did it, for whom has got the same problem modify line right after <?php to something like
if (session_id() == '') {
session_cache_limiter(false);session_start();
}
My tests showed no sie effects, but sure there is a posibility to have ones,
I´ll try when I got the time to make a template file just for the contact form and include the no-cache setting in the header of that template file to prevent client caching for the contact form.
Besides that little problem that annoyed me a bit I´m absolutely happy with Get Simple, Lean, Fast and supereasy to make your own template, try that with wordpress or even joomla......
Posts: 6,266
Threads: 181
Joined: Sep 2011
Heres the docs
http://php.net/manual/en/function.sessio...imiter.php
However, It fails to explain why these settings exist of for what desired purpose they serve, I mean specifically of course.
Posts: 8
Threads: 2
Joined: Feb 2015
Well, I guess the purpose is to have the possibility to control caching if needed.
In my case that contact form session caused a no-cache at all pages, which I don´t want to, my site (
www.casademaria.com.br) is quite heavy, some large photos.... caching is a must I think, and google site speed also complains if caching switched of.
Nice would be to have the possibility to activate certain plugins just for the desired page where you need/want the plugin.
Posts: 6,266
Threads: 181
Joined: Sep 2011
I mean for each option, what scenario they exist for or what desired function you use them for, that is left to figure out per specific design or requirement.
If your session is for security, it could create issues forcing cache on for example.