In your particular case, this should be enough:
var hasActive = $('.acc_trigger').hasClass("active"); // Bool. TRUE / FALSE if(hasActive){ // do something if TRUE }
Otherwise, you can go directly to the existence of the element
$('.acc_trigger.active').css({background: 'red'});
Live demo
By the way, your HTML formatting is pretty unusual, I would rather say wrong:
DIV (block level elements) must not be inside A (built-in) elements
source share