How to hide elements in bootstrap: 1. Open the corresponding code file; 2. Hide the element in bootstrap by adding the "display:none;" or "visibility:hidden;" style to the element.
The operating environment of this tutorial: windows7 system, bootstrap3 version, Dell G3 computer.
Tips for displaying and hiding DIV
Use bootstrap’s 12-point grid to demonstrate
style="display: none;" Release the occupancy after hiding Page space
document.getElementById("typediv1").style.display="none";//隐藏 document.getElementById("typediv1").style.display="";//显示
Method:
style="max-width:90%" 隐藏后不释放空间 document.getElementById("typediv1").style.visibility="hidden";//隐藏 document.getElementById("typediv1").style.visibility="visible";//显示
Code:
Recommended related tutorials :《bootstrap tutorial》
The above is the detailed content of How to hide elements in bootstrap. For more information, please follow other related articles on the PHP Chinese website!