• Dynamic pages and caching

    From groovee@cyberdude.com@21:1/5 to All on Fri Aug 9 00:58:16 2019
    I was just shopping groceries on a site. I searched "potato" on it and got a list of results. Then I went to some other page. *Then* I happened to click the Back button. Firefox showed me a "We need to resend your query to the server"...blah blah. What
    does this mean??? Can Firefox tell the difference between a static page and a dynamic one? What is the relationship between dynamic pages and caching exactly? If a page is dynamic, does that automatically MEAN that the server needs to be hit every time
    it's fetched? (doesn't APPEAR to be the case - there are other sites which do not show this behaviour).
    I suspect what happened was that these guys turned OFF the cache totally for that page - like, why?? :) Are there going to be 2000 different varieties of potatoes being added to the site/sec?? :) If you were the site maker, is there some way to turn off
    caching ONLY FOR DYNAMIC PAGES, somehow?? - just out of curiosity?? How?? (nasty Apache conf file fiddling, right?? :( )


    Thanks.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Robert Wessel@21:1/5 to groovee@cyberdude.com on Fri Aug 9 05:12:11 2019
    On Fri, 9 Aug 2019 00:58:16 -0700 (PDT), groovee@cyberdude.com wrote:

    I was just shopping groceries on a site. I searched "potato" on it and got a list of results. Then I went to some other page. *Then* I happened to click the Back button. Firefox showed me a "We need to resend your query to the server"...blah blah. What
    does this mean??? Can Firefox tell the difference between a static page and a dynamic one? What is the relationship between dynamic pages and caching exactly? If a page is dynamic, does that automatically MEAN that the server needs to be hit every time
    it's fetched? (doesn't APPEAR to be the case - there are other sites which do not show this behaviour).
    I suspect what happened was that these guys turned OFF the cache totally for that page - like, why?? :) Are there going to be 2000 different varieties of potatoes being added to the site/sec?? :) If you were the site maker, is there some way to turn off
    caching ONLY FOR DYNAMIC PAGES, somehow?? - just out of curiosity?? How?? (nasty Apache conf file fiddling, right?? :( )


    If I understand your question correctly, this is the result of a web
    page using a POST (as opposed to GET) HTTP request. Unlike GETs,
    POSTs may impact state on the server, so cannot be safely (re)sent -
    that's what the browser is warning you about. Usually called a
    "postback".

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Robert Wessel@21:1/5 to robertwessel2@yahoo.com on Fri Aug 9 05:18:42 2019
    On Fri, 09 Aug 2019 05:12:11 -0500, Robert Wessel
    <robertwessel2@yahoo.com> wrote:

    On Fri, 9 Aug 2019 00:58:16 -0700 (PDT), groovee@cyberdude.com wrote:

    I was just shopping groceries on a site. I searched "potato" on it and got a list of results. Then I went to some other page. *Then* I happened to click the Back button. Firefox showed me a "We need to resend your query to the server"...blah blah. What
    does this mean??? Can Firefox tell the difference between a static page and a dynamic one? What is the relationship between dynamic pages and caching exactly? If a page is dynamic, does that automatically MEAN that the server needs to be hit every time
    it's fetched? (doesn't APPEAR to be the case - there are other sites which do not show this behaviour).
    I suspect what happened was that these guys turned OFF the cache totally for that page - like, why?? :) Are there going to be 2000 different varieties of potatoes being added to the site/sec?? :) If you were the site maker, is there some way to turn
    off caching ONLY FOR DYNAMIC PAGES, somehow?? - just out of curiosity?? How?? (nasty Apache conf file fiddling, right?? :( )


    If I understand your question correctly, this is the result of a web
    page using a POST (as opposed to GET) HTTP request. Unlike GETs,
    POSTs may impact state on the server, so cannot be safely (re)sent -
    that's what the browser is warning you about. Usually called a
    "postback".


    As to caching, it can be controlled on a per-page basis with the
    Cache-Control parameter, although it doesn't directly prevent caching,
    it is supposed to make the browser use one of the "If-" parameters to
    validate the page - but that doesn't usually result in the "need to
    resend" message.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Barry Margolin@21:1/5 to Robert Wessel on Mon Aug 12 00:54:24 2019
    In article <1phqkeh0a1uotgg9ub0h1dptuintjiqtnm@4ax.com>,
    Robert Wessel <robertwessel2@yahoo.com> wrote:

    On Fri, 09 Aug 2019 05:12:11 -0500, Robert Wessel
    <robertwessel2@yahoo.com> wrote:

    On Fri, 9 Aug 2019 00:58:16 -0700 (PDT), groovee@cyberdude.com wrote:

    I was just shopping groceries on a site. I searched "potato" on it and got >>a list of results. Then I went to some other page. *Then* I happened to >>click the Back button. Firefox showed me a "We need to resend your query to >>the server"...blah blah. What does this mean??? Can Firefox tell the >>difference between a static page and a dynamic one? What is the >>relationship between dynamic pages and caching exactly? If a page is >>dynamic, does that automatically MEAN that the server needs to be hit every >>time it's fetched? (doesn't APPEAR to be the case - there are other sites >>which do not show this behaviour).
    I suspect what happened was that these guys turned OFF the cache totally >>for that page - like, why?? :) Are there going to be 2000 different >>varieties of potatoes being added to the site/sec?? :) If you were the site >>maker, is there some way to turn off caching ONLY FOR DYNAMIC PAGES, >>somehow?? - just out of curiosity?? How?? (nasty Apache conf file fiddling, >>right?? :( )


    If I understand your question correctly, this is the result of a web
    page using a POST (as opposed to GET) HTTP request. Unlike GETs,
    POSTs may impact state on the server, so cannot be safely (re)sent -
    that's what the browser is warning you about. Usually called a
    "postback".


    As to caching, it can be controlled on a per-page basis with the Cache-Control parameter, although it doesn't directly prevent caching,
    it is supposed to make the browser use one of the "If-" parameters to validate the page - but that doesn't usually result in the "need to
    resend" message.

    But browsers never cache the result of a POST, AFAIK, so cache control
    is irrelevant there.

    --
    Barry Margolin
    Arlington, MA

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Robert Wessel@21:1/5 to barmar@alum.mit.edu on Mon Aug 12 15:10:16 2019
    On Mon, 12 Aug 2019 00:54:24 -0400, Barry Margolin
    <barmar@alum.mit.edu> wrote:

    In article <1phqkeh0a1uotgg9ub0h1dptuintjiqtnm@4ax.com>,
    Robert Wessel <robertwessel2@yahoo.com> wrote:

    On Fri, 09 Aug 2019 05:12:11 -0500, Robert Wessel
    <robertwessel2@yahoo.com> wrote:

    On Fri, 9 Aug 2019 00:58:16 -0700 (PDT), groovee@cyberdude.com wrote:

    I was just shopping groceries on a site. I searched "potato" on it and got >> >>a list of results. Then I went to some other page. *Then* I happened to
    click the Back button. Firefox showed me a "We need to resend your query to
    the server"...blah blah. What does this mean??? Can Firefox tell the
    difference between a static page and a dynamic one? What is the
    relationship between dynamic pages and caching exactly? If a page is
    dynamic, does that automatically MEAN that the server needs to be hit every
    time it's fetched? (doesn't APPEAR to be the case - there are other sites >> >>which do not show this behaviour).
    I suspect what happened was that these guys turned OFF the cache totally >> >>for that page - like, why?? :) Are there going to be 2000 different
    varieties of potatoes being added to the site/sec?? :) If you were the site
    maker, is there some way to turn off caching ONLY FOR DYNAMIC PAGES,
    somehow?? - just out of curiosity?? How?? (nasty Apache conf file fiddling,
    right?? :( )


    If I understand your question correctly, this is the result of a web
    page using a POST (as opposed to GET) HTTP request. Unlike GETs,
    POSTs may impact state on the server, so cannot be safely (re)sent -
    that's what the browser is warning you about. Usually called a
    "postback".


    As to caching, it can be controlled on a per-page basis with the
    Cache-Control parameter, although it doesn't directly prevent caching,
    it is supposed to make the browser use one of the "If-" parameters to
    validate the page - but that doesn't usually result in the "need to
    resend" message.

    But browsers never cache the result of a POST, AFAIK, so cache control
    is irrelevant there.


    I was unclear. The OP was really asking two different questions, or
    at least speculating on the answer to their first. POST responses
    don't get cached (and are likely the cause of the effect the OP is
    asking about), caching of GET responses can be controlled.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)