I want to do something like this:
<img src="" class="after-all" data="/assets/huge-bg.png" /> <div class="after-all" data="/actions/div-content.html"></div> And in JS
$("after-all").loadMissing(); I think the best way is build a plugin with recognize method:
if (img) $(this).attr('src', $(this).attr('data')); if (div) $(this).load($(this).attr('data')); Is this possible ? What is the best way to do this ? How to do this ?