Hi I want to make the carousel responsive in order for the image to be full at mobile too, I manage to do it by changing the background-size from “cover” to “100%” in the main css. But the height is still the same. I am a total noob, I am an student actually, so I kind of understand Rubel answer, I mean if I remove the code from the main.js I can add my own height, but I don’t know how to do it. Can you explain to me?
ivanov ibu
4 years agoHow to Change Height slider id Home?
Rubel Miah Staff
4 years agoHi,
It’s a window height, If you set custom height please remove the code from js>main.js
jQuery(window).load(function(){‘use strict’;
// Slider Height
var slideHeight = $(window).height();
$(‘#home .carousel-inner .item, #home .video-container’).css(‘height’,slideHeight);
$(window).resize(function(){‘use strict’,
$(‘#home .carousel-inner .item, #home .video-container’).css(‘height’,slideHeight);
});
});
Then set your custom height.
Thanks.
haiku23
4 years agoHi I want to make the carousel responsive in order for the image to be full at mobile too, I manage to do it by changing the background-size from “cover” to “100%” in the main css. But the height is still the same. I am a total noob, I am an student actually, so I kind of understand Rubel answer, I mean if I remove the code from the main.js I can add my own height, but I don’t know how to do it. Can you explain to me?