Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Arun 136 posts 369 karma points
    Mar 19, 2020 @ 13:37
    Arun
    0

    Old values is displayed when clicked browser back button

    Hi,
    I have a page where i can increase/decrease the order count. The order count altering is handled by teaCommerceEvents.js and i can see the price is also adjusting precisely (updated with ajax in afterCartUpdated).

    But when i click forward to next page and then i clicked back button of browser and reached the former page, Then the price data's were wrong. I confirmed that these prices were the same as when the page was loaded initially.


    Is there any option to update these values when browser back button is clicked.?

    Regards
    -Arun

  • Arun 136 posts 369 karma points
    Jun 14, 2020 @ 05:37
    Arun
    0

    As i didn't get any other options i have given code in document.ready section in js to update each values.
    -Arun

  • Steve Morgan 1346 posts 4453 karma points c-trib
    Jun 15, 2020 @ 08:15
    Steve Morgan
    0

    Have you set the cache control settings on your pages. If your content is dynamic and can be changed you need to tell the browser it's lifetime is a single load.

    See the answer from "Marlon" here: https://stackoverflow.com/questions/43043113/how-to-force-reloading-a-page-when-using-browser-back-button

Please Sign in or register to post replies

Write your reply to:

Draft