Hole Punch on Div tag

Discussion in 'LiteMage Cache Extension For Magento' started by Radu, Jul 15, 2017.

Tags:
  1. Radu

    Radu New Member

    Hi,
    My client is currently using litemage for magento. They have a plugin to add badges to images in magento.

    We wanted these badges not to be included in the cache and to apply a hole punch to them. We have ready through the documentation but it is referring to custom blocks and these badges are not a custom block.

    See here on product images you see "LED Included" badge over the thumbnail

    Code:
    https://www.micalighting.com.au/new-lighting-arrivals/indoor-ceiling-lighting-new-arrivals.html
    This is a <div> tag that sits on top of the thumbnail

    Is there any way to exclude this from the cache but leave everything else as it is ?
    Thanks
     
    Last edited by a moderator: Jul 17, 2017
  2. Lauren

    Lauren LiteSpeed Staff Staff Member

    First, hole punch is not defined by div tag, it is defined by block name in the layout file. My question is why do you want to not cache the badge? LED included should not change dynamically for a product. I need to understand the use cases, there may be other solutions to it.
     
  3. Radu

    Radu New Member

    Thanks for fast response!!! The issue is this...

    If client adds a new badge it wont show it on the products it is applied to until the cache is cleared or product is saved and cache cleared that way.

    The problem with this is sometimes the rule might involve hundreds of products and its very time consuming to update them all.

    Now when cache is off this was never an issue. With cache on its not showing the badge as that page is cached from before the badge was added.

    Hope that explains a bit better?
     

Share This Page