- This topic is empty.
Viewing 6 posts - 1 through 6 (of 6 total)
Viewing 6 posts - 1 through 6 (of 6 total)
- The forum ‘CSS’ is closed to new topics and replies.
The forums ran from 2008-2020 and are now closed and viewable here as an archive.
I’m using the code from this tutorial :
http://thecodeplayer.com/walkthrough/css3-image-slider-with-stylized-thumbnails
For some reason the transition effects only work if the css is applied inline but I would prefer to keep the css in a stylesheet. Any ideas why the transitions aren’t working when the css is called externally? I don’t think there’s an issue with how I have linked to the stylesheet?
link to site?
http://mbmitservices.co.uk/slider.htm
The transition effects only work in Firefox and IE10 if I link to an external stylesheet but if you look at the demo in the original link :
http://thecodeplayer.com/walkthrough/css3-image-slider-with-stylized-thumbnails
They work in chrome and opera as well.
You forgot to add prefixes. (-webkit-transform, -moz-transform, -o-transform etc..) line 54 and 25.
That wasn’t mentioned in the tutorial! Thanks working now :
.slider>img{
position: absolute;
left: 0; top: 0;
transition: all 0.5s;
-webkit-transition: all 0.5s;
-moz-transition: all 0.5s;
-o-transition : all 0.5s;
}
.slider input[name=’slide_switch’] ~ img {
opacity: 0;
transform: scale(1.1);
-webkit-transform: scale(1.1);
-moz-transform: scale(1.1);
-o-transform : scale(1.1);
}
.slider input[name=’slide_switch’]:checked+label+img {
opacity: 1;
transform: scale(1);
-webkit-transform: scale(1);
-moz-transform: scale(1);
-o-transform : scale(1);
}
One final issue with the script is that on an actual mobile device (i.e. not resizing a browser window on a PC) the thumbnails do not change the main slider image and that goes for the original code from the codeplayer link. Any idea why?