总的来说,基本上所有的浏览器都支持display:none、display:inline、display:block和visibility:visible、visibility:hidden等几个样式。他们之间有什么不一样呢?
<div id="divTest" style="background-color: green;">This is only for test!</div>
<input type="button" value="display:none" onclick="document.getElementById('divTest').style.display='none';" />
<input type="button" value="display:block" onclick="document.getElementById('divTest').style.display='block';" />
<input type="button" value="visibility:hidden" onclick="document.getElementById('divTest').style.visibility='hidden';" />
<input type="button" value="visibility:visible" onclick="document.getElementById('divTest').style.visibility='visible';" />