Hello. Trying to implement AnythingSlider with a 100% width and height that will adjust to maintain the correct image ratio (ie not stretch the image). I was able to setup the slider with 100% width without a problem, but I’m having trouble getting the height to adjust.
Currently I have the parent container set to a fixed height, but when it is removed or set to 100% the slider collapses. Any thoughts on how to fix?
The images inside of AnythingSlider are 1161×500 in size, or they have an aspect ration of approximately 2.3 (1161 divided by 500).
So what that code does is applies that same aspect ratio to the container around AnythingSlider (#wrapper1). And since the “expand” option is true, the slider will expand to fit inside of that container and maintain the ratio you want.