Closed gety9 closed 7 years ago
Hello @gety9 unfortunately FPC comes to its limits if you have dynamic data that is binded to a product or stock model. If you have not so often orders, a possible solution would be cleaning FPC product specific. An other solution is to load those data via AJAX in my eyes.
@GordonLesti
Thank you for AJAX suggestions, As far as i understand AJAX is the way it should be implemented in the first place, correct? (checked common booking platforms such as fareharbor, and they load all availability data using json)
Please head me in the right direction:
On our page we have custom booking extension that uses inlined javascript to control tour availability for different days and time options.
Since all block is same, it's only js variables that change, i would prefer to keep cache for the block, and not cache only js part.
What's the right way to do it?
Here is part of js, these vars are the ones that changing (the var arrays are much longer, it's just shorter version):
They are taken from database table which is updated every time order is made. Should we somehow make the js dynamic/lazy and update it everytime order is made?
Or should we put the inlined js in external js file? (would it prevent FPC from caching it?)