I think that you do not just need a click, but would also like to close the previously opened panels, and then check this code:
$('h3','.horizontalaccordion ul li').click(function() {
$('*[class*=hover]').removeClass('hover');
$(this).closest('li').addClass('hover');
});
JsFiddle example
I hope this works for you!