I am using jquery to dynamically create an active state using Flexslider's API. Here is my jQuery:
var curslide = slider.animatingTo;
var parsed = parseInt(curslide);
$("#pillarControl li").each(function(){
$(this).removeClass("active");
});
$("#pillarControl li a[rel='parsed']").parent().addClass("active");
THe bottom line is NOT working. If I replace parsed
with an actual integer, it works great. But for some reason, the variable parsed
is not causing the active class to be added. I did a test to see if the variable parsed
had the correct value stored, and it does. Seems to be a syntax problem? Not sure, any ideas?