导航

用户登录

聚合

聚合内容

在线用户

目前共有 0 位用户0 位游客在线。

ie prototype table hover

prototype table hover ie 解决方案

样式表

table.hover tr:hover, table.hover tr.hover
{
background-color:#ffffcc;
}

prototype

$$('table.hover tr').each( function(e) {
e.onmouseover += function() {
Element.addClassName(e, 'hover');
};
e.onmouseout += function() {
Element.removeClassName(e, 'hover');
}
});

加入 !window.XMLHttpRequest 只对ie6以前版本

# if (!window.XMLHttpRequest)
# {
...
}

如果已经有了 onmouseover 事件,则需要 observe 方法

1. if (!window.XMLHttpRequest)
2. {

guoshuang 于 周三, 04/02/2008 - 13:38 提交。
by guoshuang 2007 with drupal. RSS Sitemap