Skip to content Skip to sidebar Skip to footer

Use Jquery To Change Css Height Of Slider Based On Window Size

I've found solutions very close to what I want, but because of my limited programming experience, I can't make them work for me. What I want to do is change a parameter inside two

Solution 1:

This is how you may write your conditions:

$(window).on('load resize', function () {
  var w = $(window).width();
  $("#rev_slider_1_1 #rev_slider_1_1_wrapper")
    .css('max-height', w > 1280 ? 515 : w > 480 ? 615 : 715);
});

Post a Comment for "Use Jquery To Change Css Height Of Slider Based On Window Size"