[geeklog-devel] Help regarding Feature Request #1606, identifying a page refresh
rishabhr123 at gmail.com
Sun May 19 08:44:33 EDT 2013
This is regarding discussion about a feature request #1606.
Currently the hit counter for an article or a story also increases if we
keep on refreshing the page.
This may result in unwanted spam increases of the view.
The solution boils down to "how to identify that a page has been loaded by
a refresh (simple F5 / Ctrl + F5 (cache clear too) ).
I had an idea in mind that the _SERVER(HTTP_REFERER) variable should change
value upon refreshing the page, but after trying it out, it does not seem
to work, the value remains constant.
Interestingly upon "refreshing the page" two other server variables are
introduced in the _SERVER array, namely "HTTP_CACHE_CONTROL" with the value
as "max-age=0" and "HTTP_PRAGMA" with the value as "no-cache". These
basically indicate that the content is not to be served from the cache.
Is a solution involving checking the set state of these two variables
Any other ideas as to how to identify a page-refresh ?
International Institute of Information Technology
Gachibowli, Hyderabad 500032
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the geeklog-devel