4 Replies Latest reply on May 22, 2014 3:21 PM by Carl Von Stetten

    cache query result issue

    iccsi Level 1

      I have a link on the form to modify a table for the drop down select control.

      The link works to add or modify data, but when I come back data entry form, the drop down does not refresh data. It remains same drop down, it does not add or modify the drop down.

      It seems the drop down keep cache memory.

      I would like to know are there any way to refresh the drop down box after user modify the physical drop down table.

       

      Your  help and information is great appreciated,

       

      Regards,

       

       

      Iccsi,

        • 1. Re: cache query result issue
          Carl Von Stetten Adobe Community Professional & MVP

          iccsi,

           

          You need to provide more detail about how the "add or modify data" link works (does it open a modal window, a pop-up window, navigate to a different page, etc.) and how you "come back data entry form".  Then we can see if there is a way to do what you want.

          -Carl V.

          • 2. Re: cache query result issue
            iccsi Level 1

            Thanks for the information and help,

            I use navigate to another page and edit the data on a new browser.

            after come back, the drop down does not have new record just added.

            Are there any property to configure for a drop down always clear cache memory?

             

            Thanks again for helping,

             

            Regards,

             

            Iccsi,

            • 3. Re: cache query result issue
              BKBK Adobe Community Professional & MVP

              You could just prevent the page from being cached. You could do that, for example, by placing the following at the top of the page:

               

              <cfheader name="Cache-Control" value="no-cache,no-store,must-revalidate">

              <cfheader name="Pragma" value="no-cache">

              <cfheader name="Expires" value="-1">

              • 4. Re: cache query result issue
                Carl Von Stetten Adobe Community Professional & MVP

                Yeah, still not entirely clear. 

                I use navigate to another page and edit the data on a new browser.

                Does "a new browser" mean a pop-up window (a separate browser window)?  Does the original page that contains the link remain open in the original browser window?  If yes to both, then getting the first page to refresh can be tricky.  The 2nd window (the editing window) might have access to the 1st window to initiate a refresh of the window using the window.onClose() JavaScript function.  I think I'm doing something similar to this in one of my applications.  I don't recommend this approach though, especially if there are any forms on the 1st page as it could result in uninteded loss of user information.  How?  Here's what happens in my application (and I intend to rework this when I have time):

                1. 1st page has a form and links to a pop-up window with a different form.
                2. User starts filling in form on 1st page, then clicks link that opens pop-up window before submitting the form.
                3. User edits data on pop-up window form and submits the form (which closes the pop-up window).
                4. The window.onClose() function of the pop-up window tells the 1st page to refresh to see updated information.
                5. The 1st page refreshes, and all of the unsubmitted edits to the form on this page are lost.

                 

                However, if my understanding of how your application works is incorrect, then I think BKBK's tip will work.  And just to clarify: the configuration of your drop down (HTML <select> element) is not stored in your browser cache, your entire page is stored in cache. Which is why BKBK's suggestion would accomplish what you want.

                 

                -Carl V.