http://www.ggaeal.com/bbs/board.php?bo_table=humor
위 게시판처럼 게시글 제목에 마우스를 갖다대면 색이 바뀌는 효과에 대해 묻고싶습니다.
style.css 손대면 된다는데 구체적으로 어떻게?
참고로 배추베이직 사용중입니다.
위 게시판처럼 게시글 제목에 마우스를 갖다대면 색이 바뀌는 효과에 대해 묻고싶습니다.
style.css 손대면 된다는데 구체적으로 어떻게?
참고로 배추베이직 사용중입니다.
댓글 3개
table row 는 css 로 먹이는게 아니구요, (제가 알기로는 어떤 경우에도 legacy 브라우저 (IE 란 얘깁니다. ㅎㅎ 한국은 IE 하위 버전이 중요하죠. ^^) 에서는 css 로 안되는걸로 알고 있습니다.)
자스로 먹이셔야 합니다.
reference 하신 저 사이트에서는
onmouseover="this.style.backgroundColor="#f2f0f;" onmouseout="this.style.backgroundColor="#ffffff"
이런식으로 자스로 background-color 를 마우스 오버시 색상을 바꾸고 있구요, jQuery 로 function 을 짜는 방법도 있습니다.
이런식으로.
$(function() {
$("table").delegate('td','mouseover mouseleave', function(e) {
if (e.type == 'mouseover') {
$(this).parent().addClass("hover");
$("colgroup").eq($(this).index()).addClass("hover");
} else {
$(this).parent().removeClass("hover");
$("colgroup").eq($(this).index()).removeClass("hover");
}
});
});
암튼 css 로는 해결방법이 아닙니다.
자스로 먹이셔야 합니다.
reference 하신 저 사이트에서는
onmouseover="this.style.backgroundColor="#f2f0f;" onmouseout="this.style.backgroundColor="#ffffff"
이런식으로 자스로 background-color 를 마우스 오버시 색상을 바꾸고 있구요, jQuery 로 function 을 짜는 방법도 있습니다.
이런식으로.
$(function() {
$("table").delegate('td','mouseover mouseleave', function(e) {
if (e.type == 'mouseover') {
$(this).parent().addClass("hover");
$("colgroup").eq($(this).index()).addClass("hover");
} else {
$(this).parent().removeClass("hover");
$("colgroup").eq($(this).index()).removeClass("hover");
}
});
});
암튼 css 로는 해결방법이 아닙니다.
게시글 목록
| 번호 | 제목 |
|---|---|
| 284508 | |
| 284499 | |
| 284492 | |
| 284490 | |
| 284484 | |
| 284481 | |
| 284478 | |
| 284476 | |
| 284474 | |
| 284472 | |
| 284470 | |
| 284458 | |
| 284457 | |
| 284454 | |
| 284453 | |
| 284447 | |
| 284446 | |
| 284444 | |
| 284441 | |
| 284440 |
댓글 작성
댓글을 작성하시려면 로그인이 필요합니다.
로그인하기