Why doesn't my css transitions work in firefox? I mean the ease-in-out? It works in chrome and safari. I have googel'd and done research here in stackoverflow and I really, really hope it is not because firefox dosen't support this???
css
body{
background: url("../img/background.jpg") no-repeat center center fixed;
-webkit-background-size: cover;
-moz-background-size: cover;
-o-background-size: cover;
background-size: cover;
overflow-y: hidden;
-webkit-transition: background ease-in-out 0.5s;
-moz-transition: background ease-in-out 0.5s;
-o-transition: background ease-in-out 0.5s;
transition: background ease-in-out 0.5s;
}
.background-0 {
background: url("../img/ff.jpg") no-repeat center center fixed;
}
.background-1 {
background: url("../img/ddd.jpg") no-repeat center center fixed;
}
.background-2 {
background: url("../img/hh.jpg") no-repeat center center fixed;
}
.background-0,
.background-1,
.background-2{
-webkit-background-size: cover;
-moz-background-size: cover;
-o-background-size: cover;
background-size: cover;
}
the html
<ul>
<li>one</li>
<li>two</li>
<li>three</li>
</ul>
script
var list_elements = $('ul li');
var current_index = null;
list_elements.on('mouseenter', function() {
current_index = list_elements.index(this);
$('body').addClass('background-' + current_index);
}).on('mouseleave', function(){
$('body').removeClass('background-' + current_index);
current_index = null;
});