大家好,我对 IE10 和 chrome 有问题。扩展表格后,IE10 不会崩溃,对于 chrome,它会在它之间留下空白空间。它在 ie8、firefox 中工作。我已经尝试过 display:none 和 display: table-row ..但它只适用于 IE 10 ..
这是javascript代码
function loadSessionLogEvents(id) {
var visibility = $('eventTR' + id).style.visibility;
if (visibility == 'collapse')
{
$('eventTR' + id).style.visibility = 'visible';
var tURL = '<%=request.getContextPath()%>/home/Folder.action?listSessionLogEvents=&sessionLogId=' + id;
new Ajax.Updater($('detailTR' + id), tURL, {
method: 'get',
evalScripts: 'hidden'
});
} else {
$('eventTR' + id).style.visibility = 'collapse';
}
}
所以我改变后的代码应该是这样的?
function loadSessionLogEvents(id) {
var visibility = $('#eventTR' + id).css('visibility');
if (visibility == 'collapse')
{
$('eventTR' + id).css('visibility','');
var tURL = '<%=request.getContextPath()%>/home/Folder.action?listSessionLogEvents=&sessionLogId=' + id;
new Ajax.Updater($('detailTR' + id), tURL, {
method: 'get',
evalScripts: 'hidden'
});
} else {
$('eventTR' + id).css('visibility','collapse');
}
}
这是点击按钮功能
href="#" onclick="javascript:loadSessionLogEvents('${file.session.id}')">