Answers for "how to set particular height for all div elements"

0

css 100% height

<!DOCTYPE html>
<html>
  <head>
    <title>100% height</title>
    <style>
      html,
      body {
        height: 100%;
        margin: 0;
      }
      .container {
        height: 100%;
        background: #000; /* to see the effect */
      }
    </style>
  </head>
  <body>
    <div class="container"></div>
  </body>
</html>
Posted by: Guest on June-13-2020
1

how to make all div same height

<html>
	<head>
    	<title>Web page</title>
    </head>
    <body>
    	<div id="divContainer">
          <div id="divOne">
          	<p>Paragraph 1</p>
            <p>Another Paragraph</p>
          </div>
          <div id="divTwo">
          	<p>Paragraph 2</p>
          </div>
        </div>
    </body>
    <style>
    	#divContainer {
        	display: flex;
        }
        #divOne {
        	background-color: red;
        }
        #divTwo {
        	background-color: blue;
        }
    </style>
</html>
Posted by: Guest on March-28-2020

Code answers related to "how to set particular height for all div elements"

Browse Popular Code Answers by Language