마우스를 올려 놓을 때 테이블 행을 강조 표시하려면 스 니펫이 필요합니다. jquery tablesorter 플러그인이 있으면이 기능을 추가 할 수 없었습니다. 테이블의 행을 강조 표시Jquery tablesorter row hover
1
A
답변
2
, 당신은 사용할 수 있습니다
$(document).ready(function() {
$("table").tablesorter();
$('table tr').has(':not(th)').hover(
function(){
$(this).data('currColor',$(this).css('background-color'));
$(this).css('background-color','#cdd');
},
function(){
$(this).css('background-color',$(this).data('currColor'));
}
);
});
4
이없이 tablesorter에의 zebra widget
에 영향을 미치는, 당신은 tablesorter에 몇 가지 추가 CSS를 추가 할 수 있습니다 /있는 style.css
table.tablesorter tr.even:hover td,
table.tablesorter tr.odd:hover td {
background-color: blue;
}
0
tablesorter와 함께 jQuery.Colorize 플러그인을 사용해 볼 수도 있습니다. 대체 색상을 유지할 수 있습니다. http://jquerycolorize.blogspot.com/2012/01/how-to-use-tablesorter-plugin-with.html
Btw, asp.net mvc를 사용하는 경우 더 좋은 옵션은 MvcContrib Grid를 사용하는 것입니다.
0
행 메타 데이터를 더 자세히 분석하려면 & 오버레이를 표시하고 싶습니다. 이 질문을 발견했지만 솔루션은 실제로 tablesorter와 제대로 작동하지 않았습니다.
http://rogtopia.com/entries/jquery-js/tablesorter-hover-with-custom-widget
tablesorter에 위젯을 만들어 호버를 재 - 추가 :이 2009 블로그 게시물에서 작동하는 솔루션을 발견했다.
<script type="text/javascript">
$(document).ready(function() {
// tablesorter widget to setup rollovers on table rows
$.tablesorter.addWidget({
id: "hover",
format: function(table) {
$('tr',$(table)).mouseover(function() {
$(this).addClass('hover');
}).mouseout(function() {
$(this).removeClass('hover');
});
}
});
// then instantiate your tablesorter calling the hover widget
$('.tablesorter').tablesorter({widthFixed: true, widgets: ['hover'] });
});
</script>
관련 문제
- 1. jquery tablesorter 필터 플러그인
- 2. 유럽인을위한 jQuery TableSorter 파서
- 3. JQuery tablesorter Ajax 정렬
- 4. tablesorter jQuery hack
- 5. Jquery Tablesorter header
- 6. jquery random color hover
- 7. IE8에서 jQuery .hover() 문제
- 8. jQuery selective hover
- 9. 캡션이있는 jquery hover 오버레이
- 10. mouseenter, mouseleave, hover jQuery
- 11. jquery hover 함수
- 12. Jquery hover 토글
- 13. Jquery Hover 깜박임 문제
- 14. jQuery help with hover
- 15. Jquery hover lock 위로
- 16. jQuery .hover 작업에 실패했습니다.
- 17. jQuery hover function
- 18. Jquery hover effect가 사라짐
- 19. jquery .hover 및 .delay
- 20. jquery hover parent div
- 21. jquery tablesorter 잘못 정렬 번호가
- 22. jQuery cycle fade on hover
- 23. jquery hover range of td
- 24. hoverIntent가있는 JQUERY hover 드롭 다운
- 25. jquery hover 및 중첩 목록
- 26. Jquery group photo hover effect
- 27. Jquery hover fadeIn/fadeOut 문제
- 28. jQuery hover 콜백 함수 문제
- 29. jQuery Hover-UnHover not working
- 30. JQuery Hover Image 스왑 문제
기존 CSS를 삭제해서는 안됩니다. – minil
그런 다음 색을 저장하십시오. 그리 어렵지 않습니다. http://jsfiddle.net/userdude/gjm6g/2/ –
(약간 수정) 나를 위해 일했습니다. 감사합니다! – Sirber