Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $('.b-select-box img').each(function(){
- $(this).css(this.height < this.width ? 'height' : 'width', selectBoxSize + 'px');
- $(this).css({position: 'relative', top: ($(this).height() - selectBoxSize) / -2 + 'px', left: ($(this).width() - selectBoxSize) / -2 + 'px'});
- alert('height: ' + $(this).height + 'px\nwidth: ' + $(this).width() + 'px');
- });
Add Comment
Please, Sign In to add comment