We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 38593
    • 129 Posts
    Not sure if this is the appropriate forum but here goes....

    We are using MODX (revo latest version) to build a product catalog using data from a remote server. Currently the snippet that gets product pricing and availability is not cached. However because the products sell slowly (big ticket items), the availability changes slowly.

    The idea being considered is to cache the snippet data, then add some code to the "shopping cart" to tell MODX to clear the cache for that product's page. That way product availability stays up to date without a ton of API calls going to the product data server every time a page is requested.

    I tried looking at the api.modx.com website, but for some reason it kept crashing my browser, so though I would ask here.

    Is there a function I can add into the "cart" confirmation page's php that would tell MODX to flush cache for a specific page? The "cart" program actually resides on the same server as MODX, but runs separately (too complex of a code for me to slice & dice for porting to MODX).
      Pedalers Bicycle Tours my website forged with MODX
      vandergraaf-M static website generator for MODX