I have a twitter bootstrap carousel component and I want to detect it's slide function, through that, foreground color of another component should be changed at each slide move.
$('#welcomeCarousel').on('slide',function(e){
var index = $(this).find('.active').index();
if(index==1) {
$('.navbar-inverse .brand:hover,
.navbar-inverse .nav > li > a:hover,
.navbar-inverse .brand:focus,
.navbar-inverse .nav > li > a:focus').css('color': 'rgb(255, 255, 255)');
}
});
I think problem occurs because of selecting multiple CSS classes, there should be sth. wrong about it because index has correct value. JS console says unexpected token or unexpected string.