I have the same problem, and have found a solution.
First of all I should say that the problem is actual for any row in table with style borderCollapse equal to collapse (no matter if it is declared inline or in head) in IE9.
My solution:
function hideRow(tableNode, rowNode, hide){
if(hide){
if(window.navigator.userAgent.search('MSIE 9.0') != -1){
var initValue = tableNode.style.borderCollapse;
tableNode.style.borderCollapse = 'separate';
rowNode.style.display = 'none';
tableNode.style.borderCollapse = initValue;
}else{
rowNode.style.display = 'none';
}
}else{
rowNode.style.display = '';
}
}
Or even shorten:
function hideRow(tableNode, rowNode, hide){
var initValue = tableNode.style.borderCollapse;
tableNode.style.borderCollapse = 'separate';
rowNode.style.display = hide ? 'none' : '';
tableNode.style.borderCollapse = initValue;
}
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…