Have tried looking around, and am getting stuck with one of my dynamic triggers.
I have checked other thread related to this, but seem to have some other code errors that might be causing the suggested .on method to fail.
The code aims to hide/show 2 separate - there are some initial pre-rendered ones, and some loaded dynamically after.
The pre-rendered are fine, the dynamic ones fail.
The Jquery:
$("div .flipper_link").on("click", function () {
$(this).parent().find(".contain_content").toggle();
$(this).parent().find(".card-tags").toggle();
});
And the dynamically created code:
<div class="callout_surround">
<div class="callout ct_shop">
<div class='header-global header-shop'>Shop</div>
<div class="flipper_link header-shop"><i class="fi-loop"></i></div>
<div class='contain_content' uid="74" data-popup-open="popup-1">
<img src='images/someimage.jpg' class='img_cont'/>
<div class='tile-text-cont'>
<div class='tile-desc'>
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Ut non scelerisque
</div>
</div>
</div>
<div class="card-tags">Some tags etc</div>
</div>
</div>
I'm fairly new to jQuery, so apologize if I'm using the wrong methods!