I've tried to trigger a hover event on a previous row in a table so I could get it's effect defined in CSS but it's not working. Basically what I have is 2 rows joined that need this border effect for mouseovers whenever either row moused over. What is a solution in jQuery for this?
jQuery
$("tr").hover(function() {
$(this).prev().trigger('mouseover');
});
CSS
tr:hover .row-right {
border-right: 10px solid #CCC;
}
mouseoverevent using JavaScript has no relation to the CSShoverproperty. See Yaron Uilel's answer for an alternative solution.