Announcement

Collapse
No announcement yet.

Forcing a page to refresh (no-cache)

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Forcing a page to refresh (no-cache)



    For those interested, the question was presented a while back
    on another list on how to keep a page from being cached by the
    browser. Someone there suggested using:

    <META HTTP-EQUIV="Pragma" CONTENT="no-cache">

    which may work on some browsers, but didn't on mine. Maybe it
    is a directive to the server... I don't know for sure. However,
    I was able to accomplish the task by adding:

    <META HTTP-EQUIV="expires" CONTENT="Mon, 31 Dec 1998 10:00:00 MDT">

    setting the expiration date well in the past as above. MSIE 3.02
    now retrieves the updated page everytime it is entered with the
    new data from my database.

    Thought this might be useful to some of you.

    Regards,

    Tom Fosson

    ----- F R E E A S S O C I A T E S P R O G R A M -----
    <A HREF ="http://www.marketingtips.com/sr/t.x/23152">http://www.marketingtips.com/sr/t.x/23152</A>
    ------------------ W E B H O S T I N G ----------------
    300 Megabytes of LIFETIME Web Space for $300 FLAT!!
    HTML, VRML, Java, C++, Perl, php3, Python - T3 connection
    Unlimited email aliases - Personal CGI-BIN Directory
    Domain Name hosting - NO SETUP FEE - NO MONTHLY FEES!
    <A HREF ="http://www.moreprofits.com/cgi-bin/view.cgi/346/">http://www.moreprofits.com/cgi-bin/view.cgi/346/</A>
    -------------------- E - W O R K S -------------------
    http://eworks.mympc.com/members/tomf.html - 200Mg LIFETIME
    WEB HOSTING for $300 - NO MONTHLY FEES - NO SETUP CHARGES
    E-COMMERCE READY - FREE SECURE SERVER - FREE TRIAL!!!
    ------------------------ e G o l d -----------------------
    https://www.e-gold.com/newacct/newac...asp?cid=102027
    ------------------ S I T E D E S I G N -----------------
    Websites designed and published by Cyberspace Publishing
    193 E Main St, #292, Chillicothe, Ohio 45601
    mailto:[email protected] * <A HREF ="http://www.amug.org/~cyberpub/">http://www.amug.org/~cyberpub/</A>


    #2
    Forcing a page to refresh (no-cache)



    Tom,

    I have 2 questions about this.
    1 - is this only necessary, or be best, on only the index page of a
    website?
    2 - I added a Back Button to my mmui.mv file. I didn't pay close
    attention to this, but when I go to the Basket Contents page, then hit
    the Back Button, I sometimes get a "Repost data from form?" (or
    something like that) grey box message. Passing between the basket page
    and going back, it looks like it's taking it from cache and not updating
    the screen to the basket contents. Would putting this line about not
    caching be used in the mmui file for this, and if so, where should it be
    put in the file?

    Thanks!

    Donna

    Cyberspace Publishing wrote:

    > For those interested, the question was presented a while back
    > on another list on how to keep a page from being cached by the
    > browser. Someone there suggested using:
    >
    > <META HTTP-EQUIV="Pragma" CONTENT="no-cache">
    >
    > which may work on some browsers, but didn't on mine. Maybe it
    > is a directive to the server... I don't know for sure. However,
    > I was able to accomplish the task by adding:
    >
    > <META HTTP-EQUIV="expires" CONTENT="Mon, 31 Dec 1998 10:00:00 MDT">
    >
    > setting the expiration date well in the past as above. MSIE 3.02
    > now retrieves the updated page everytime it is entered with the
    > new data from my database.
    >
    > Thought this might be useful to some of you.
    >
    > Regards,
    >
    > Tom Fosson
    >
    > ----- F R E E A S S O C I A T E S P R O G R A M -----
    > <A HREF ="http://www.marketingtips.com/sr/t.x/23152">http://www.marketingtips.com/sr/t.x/23152</A>
    > ------------------ W E B H O S T I N G ----------------
    > 300 Megabytes of LIFETIME Web Space for $300 FLAT!!
    > HTML, VRML, Java, C++, Perl, php3, Python - T3 connection
    > Unlimited email aliases - Personal CGI-BIN Directory
    > Domain Name hosting - NO SETUP FEE - NO MONTHLY FEES!
    > <A HREF ="http://www.moreprofits.com/cgi-bin/view.cgi/346/">http://www.moreprofits.com/cgi-bin/view.cgi/346/</A>
    > -------------------- E - W O R K S -------------------
    > http://eworks.mympc.com/members/tomf.html - 200Mg LIFETIME
    > WEB HOSTING for $300 - NO MONTHLY FEES - NO SETUP CHARGES
    > E-COMMERCE READY - FREE SECURE SERVER - FREE TRIAL!!!
    > ------------------------ e G o l d -----------------------
    > https://www.e-gold.com/newacct/newac...asp?cid=102027
    > ------------------ S I T E D E S I G N -----------------
    > Websites designed and published by Cyberspace Publishing
    > 193 E Main St, #292, Chillicothe, Ohio 45601
    > mailto:[email protected] * <A HREF ="http://www.amug.org/~cyberpub/">http://www.amug.org/~cyberpub/</A>
    >

    Comment


      #3
      Forcing a page to refresh (no-cache)



      Donna,

      I can't help with Miva Merchant because I don't have Merchant
      installed. Perhaps someone on the merchant-users list could
      answer merchant specific questions.

      I, personally, use the lines on the specific pages that I want
      to be refreshed each time they are accessed. I am currently
      working on a project where the viewer of a "Top 100" page can
      vote for their favorite three sites. Once they have voted,
      they are taken back to the display page that is dynamically
      updated with the new votes. The display page uses SSI calls to
      include a header file, left and right column files, a footer
      file and a SSI call to a Miva script to display the site data
      sorted in reverse vote-count order in the center of the page.

      Until I added the lines to refresh the page, the page always
      displayed the old data on return and would only show the new
      data by doing a manual 'refresh' (or 'reload' with Netscape.)
      After adding the lines, the page now refreshes automatically
      each time it is accessed - including coming 'back' to it with
      the "back" button.

      The 'no-cache' line as mentioned didn't work for me with IE 3.02,
      but the 'expires' line does work. By having the page 'expire'
      sometime in the past, I believe the line instructs the browser to
      get a fresh page each time it comes to it since the one it has in
      memory has 'expired' and is no longer 'valid'.

      So, the short answer to your first question is to put the line
      on the specific page(s) that you want to force 'refreshing'. If
      it is placed only on the index page, then that page is the only
      one that will be refreshed. If the page never changes, then it
      isn't needed, but it helps on pages that have constantly changing
      content.

      Regards,

      Tom Fosson

      At 09:04 AM 10/6/99 -0400, Donna wrote:
      >Tom,
      >
      >I have 2 questions about this.
      >1 - is this only necessary, or be best, on only the index page of a
      >website?
      >2 - I added a Back Button to my mmui.mv file. I didn't pay close
      >attention to this, but when I go to the Basket Contents page, then hit
      >the Back Button, I sometimes get a "Repost data from form?" (or
      >something like that) grey box message. Passing between the basket page
      >and going back, it looks like it's taking it from cache and not updating
      >the screen to the basket contents. Would putting this line about not
      >caching be used in the mmui file for this, and if so, where should it be
      >put in the file?
      >
      >Thanks!
      >
      >Donna
      >
      >Cyberspace Publishing wrote:
      >
      > > For those interested, the question was presented a while back
      > > on another list on how to keep a page from being cached by the
      > > browser. Someone there suggested using:
      > >
      > > <META HTTP-EQUIV="Pragma" CONTENT="no-cache">
      > >
      > > which may work on some browsers, but didn't on mine. Maybe it
      > > is a directive to the server... I don't know for sure. However,
      > > I was able to accomplish the task by adding:
      > >
      > > <META HTTP-EQUIV="expires" CONTENT="Mon, 31 Dec 1998 10:00:00 MDT">
      > >
      > > setting the expiration date well in the past as above. MSIE 3.02
      > > now retrieves the updated page everytime it is entered with the
      > > new data from my database.
      > >
      > > Thought this might be useful to some of you.
      > >
      > > Regards,
      > >
      > > Tom Fosson

      ----- F R E E A S S O C I A T E S P R O G R A M -----
      <A HREF ="http://www.marketingtips.com/sr/t.x/23152">http://www.marketingtips.com/sr/t.x/23152</A>
      ------------------ W E B H O S T I N G ----------------
      300 Megabytes of LIFETIME Web Space for $300 FLAT!!
      HTML, VRML, Java, C++, Perl, php3, Python - T3 connection
      Unlimited email aliases - Personal CGI-BIN Directory
      Domain Name hosting - NO SETUP FEE - NO MONTHLY FEES!
      <A HREF ="http://www.moreprofits.com/cgi-bin/view.cgi/346/">http://www.moreprofits.com/cgi-bin/view.cgi/346/</A>
      -------------------- E - W O R K S -------------------
      http://eworks.mympc.com/members/tomf.html - 200Mg LIFETIME
      WEB HOSTING for $300 - NO MONTHLY FEES - NO SETUP CHARGES
      E-COMMERCE READY - FREE SECURE SERVER - FREE TRIAL!!!
      ------------------------ e G o l d -----------------------
      https://www.e-gold.com/newacct/newac...asp?cid=102027
      ------------------ S I T E D E S I G N -----------------
      Websites designed and published by Cyberspace Publishing
      193 E Main St, #292, Chillicothe, Ohio 45601
      mailto:[email protected] * <A HREF ="http://www.amug.org/~cyberpub/">http://www.amug.org/~cyberpub/</A>

      Comment


        #4
        Forcing a page to refresh (no-cache)



        Tom,

        Thanks for the info. In my case I think I should keep the line in the index
        page to be sure, and any other pages that people might want to major
        bookmark. Putting it in every page would slow things down otherwise (defeats
        the purpose of cache).

        And I still need to find the answer to my #2 question. Maybe someone on the
        list has the answer to this? (I saw it somewhere a while back but can't find
        it now.)

        Donna


        Cyberspace Publishing wrote:

        > Donna,
        >
        > I can't help with Miva Merchant because I don't have Merchant
        > installed. Perhaps someone on the merchant-users list could
        > answer merchant specific questions.
        >
        > I, personally, use the lines on the specific pages that I want
        > to be refreshed each time they are accessed. I am currently
        > working on a project where the viewer of a "Top 100" page can
        > vote for their favorite three sites. Once they have voted,
        > they are taken back to the display page that is dynamically
        > updated with the new votes. The display page uses SSI calls to
        > include a header file, left and right column files, a footer
        > file and a SSI call to a Miva script to display the site data
        > sorted in reverse vote-count order in the center of the page.
        >
        > Until I added the lines to refresh the page, the page always
        > displayed the old data on return and would only show the new
        > data by doing a manual 'refresh' (or 'reload' with Netscape.)
        > After adding the lines, the page now refreshes automatically
        > each time it is accessed - including coming 'back' to it with
        > the "back" button.
        >
        > The 'no-cache' line as mentioned didn't work for me with IE 3.02,
        > but the 'expires' line does work. By having the page 'expire'
        > sometime in the past, I believe the line instructs the browser to
        > get a fresh page each time it comes to it since the one it has in
        > memory has 'expired' and is no longer 'valid'.
        >
        > So, the short answer to your first question is to put the line
        > on the specific page(s) that you want to force 'refreshing'. If
        > it is placed only on the index page, then that page is the only
        > one that will be refreshed. If the page never changes, then it
        > isn't needed, but it helps on pages that have constantly changing
        > content.
        >
        > Regards,
        >
        > Tom Fosson
        >
        > At 09:04 AM 10/6/99 -0400, Donna wrote:
        > >Tom,
        > >
        > >I have 2 questions about this.
        > >1 - is this only necessary, or be best, on only the index page of a
        > >website?
        > >2 - I added a Back Button to my mmui.mv file. I didn't pay close
        > >attention to this, but when I go to the Basket Contents page, then hit
        > >the Back Button, I sometimes get a "Repost data from form?" (or
        > >something like that) grey box message. Passing between the basket page
        > >and going back, it looks like it's taking it from cache and not updating
        > >the screen to the basket contents. Would putting this line about not
        > >caching be used in the mmui file for this, and if so, where should it be
        > >put in the file?
        > >
        > >Thanks!
        > >
        > >Donna
        > >
        > >Cyberspace Publishing wrote:
        > >
        > > > For those interested, the question was presented a while back
        > > > on another list on how to keep a page from being cached by the
        > > > browser. Someone there suggested using:
        > > >
        > > > <META HTTP-EQUIV="Pragma" CONTENT="no-cache">
        > > >
        > > > which may work on some browsers, but didn't on mine. Maybe it
        > > > is a directive to the server... I don't know for sure. However,
        > > > I was able to accomplish the task by adding:
        > > >
        > > > <META HTTP-EQUIV="expires" CONTENT="Mon, 31 Dec 1998 10:00:00 MDT">
        > > >
        > > > setting the expiration date well in the past as above. MSIE 3.02
        > > > now retrieves the updated page everytime it is entered with the
        > > > new data from my database.
        > > >
        > > > Thought this might be useful to some of you.
        > > >
        > > > Regards,
        > > >
        > > > Tom Fosson
        >
        > ----- F R E E A S S O C I A T E S P R O G R A M -----
        > <A HREF ="http://www.marketingtips.com/sr/t.x/23152">http://www.marketingtips.com/sr/t.x/23152</A>
        > ------------------ W E B H O S T I N G ----------------
        > 300 Megabytes of LIFETIME Web Space for $300 FLAT!!
        > HTML, VRML, Java, C++, Perl, php3, Python - T3 connection
        > Unlimited email aliases - Personal CGI-BIN Directory
        > Domain Name hosting - NO SETUP FEE - NO MONTHLY FEES!
        > <A HREF ="http://www.moreprofits.com/cgi-bin/view.cgi/346/">http://www.moreprofits.com/cgi-bin/view.cgi/346/</A>
        > -------------------- E - W O R K S -------------------
        > http://eworks.mympc.com/members/tomf.html - 200Mg LIFETIME
        > WEB HOSTING for $300 - NO MONTHLY FEES - NO SETUP CHARGES
        > E-COMMERCE READY - FREE SECURE SERVER - FREE TRIAL!!!
        > ------------------------ e G o l d -----------------------
        > https://www.e-gold.com/newacct/newac...asp?cid=102027
        > ------------------ S I T E D E S I G N -----------------
        > Websites designed and published by Cyberspace Publishing
        > 193 E Main St, #292, Chillicothe, Ohio 45601
        > mailto:[email protected] * <A HREF ="http://www.amug.org/~cyberpub/">http://www.amug.org/~cyberpub/</A>
        >

        Comment

        Working...
        X