Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $(function(){
- $(document).ready(function(){
- var i = 1;
- $('.discount h2').each(function(){
- if (i == 1) {
- i++;
- var firstDiscount = $(this),
- heightFirst = firstDiscount.height();
- } else {
- i--;
- var secondDiscount = $(this),
- heightSecond = secondDiscount.height();
- if (heightSecond > heightFirst) {
- console.log('ok');
- }
- console.log(heightFirst);
- console.log(heightSecond);
- return false;
- }
- });
- });
- });
Add Comment
Please, Sign In to add comment