Please note, this is a STATIC archive of website www.tutorialspoint.com from 11 May 2019, cach3.com does not collect or store any user information, there is no "phishing" involved.
Tutorialspoint

Hidden Bootstrap class

What is the role of hidden class in Bootstrap? How can I work with it effectively to hide content?


1 Answer
Anvi Jain

To hide a Bootstrap class, use the .hidden class.

You can try to run the following code to hide a class:

Example

Live Demo

<!DOCTYPE html>
<html>
   <head>
      <title>Bootstrap Example</title>
      <link href = "/bootstrap/css/bootstrap.min.css" rel = "stylesheet">
      <script src = "/scripts/jquery.min.js"></script>
      <script src = "/bootstrap/js/bootstrap.min.js"></script>
   </head>
   <body>
      <div class = "row" style = "padding: 91px 100px 19px 50px;">
         <div class = "show" style = "left-margin:10px; width:300px; background-color:#ccc;">
            This class is visible.
         </div>
         <div class = "hidden" style = "width:200px; background-color:#ccc;">
            This is an example for hide class. This will be hidden.
         </div>
      </div>
   </body>
</html>
Advertisements

We use cookies to provide and improve our services. By using our site, you consent to our Cookies Policy.