summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorOliver Sartun <sartun@dievision.de>2015-11-12 10:33:32 +0100
committerOliver Sartun <sartun@dievision.de>2015-11-12 10:33:32 +0100
commit758d985ec529de9ef50b96914a22fc98e33354b6 (patch)
tree7f427fdd9a853593b3c3b8243fd20fd753c9dcf8
parent79b4a91fc4da9642656f83bfcb5ab74ad63b3535 (diff)
downloadjQuery.equalHeights-758d985ec529de9ef50b96914a22fc98e33354b6.zip
jQuery.equalHeights-758d985ec529de9ef50b96914a22fc98e33354b6.tar.gz
jQuery.equalHeights-758d985ec529de9ef50b96914a22fc98e33354b6.tar.bz2
Execute auto initialization on document ready
-rw-r--r--jquery.equalheights.js10
1 files changed, 6 insertions, 4 deletions
diff --git a/jquery.equalheights.js b/jquery.equalheights.js
index 561da88..8d4b41f 100644
--- a/jquery.equalheights.js
+++ b/jquery.equalheights.js
@@ -47,10 +47,12 @@
};
// auto-initialize plugin
- $('[data-equal]').each(function(){
- var $this = $(this),
- target = $this.data('equal');
- $this.find(target).equalHeights();
+ $(document).on("ready", function() {
+ $('[data-equal]').each(function(){
+ var $this = $(this),
+ target = $this.data('equal');
+ $this.find(target).equalHeights();
+ });
});
})(jQuery);