Wrap with a div 3/9

Wrap with a div
Cool! We just created a minimal navigation bar for the web page.
To stay organized, let's wrap the ul elements with two divs, like this:
<div class="nav">
  <div class="container">
    <ul>
      <li>Your Name</li>
      ...
    </ul>

    <ul>
      <li>Sign Up</li>
      ...
    </ul>
  </div>
</div>
div element groups other elements together into sections of the web page, such as a navigation bar, the main body, and the footer.
The outer <div class="nav">..</div> groups the elements into the navigation bar section of the web page. The inner <divclass="container">..</div> wraps the contents in a container. We'll use both classes in the next section to style the navigation bar.
Instructions
Wrap the ul elements with two divs, like in the example above. Give the outer div aclass="nav" and the inner div aclass="container".
Wrap with a div
<!DOCTYPE html>
<html>
  <body>
  <div class="nav">
    <div class="container">
    <ul>
      <li>Item 1</li>
      <li>Item 2</li>
    </ul>

    <ul>
      <li>Sign up</li>
      <li>Log in</li>
      <li>Help</li>
    </ul>
    <ul>
  </div>
  </div>


  </body>
</html>

Comments

Popular posts from this blog

MEGA 暫存檔案刪除

IOS GCD多執行緒

利用CMD指令強制刪除