Home > Web Front-end > HTML Tutorial > Question: About the implementation of friend classification menu_html/css_WEB-ITnose

Question: About the implementation of friend classification menu_html/css_WEB-ITnose

WBOY
Release: 2016-06-24 11:56:47
Original
1262 people have browsed it

Source: http://www.ido321.com/868.html

Post friends’ needs and realize the classification of icon menus

I would like to ask for corrections on the deficiencies in the implementation of this problem.

html:

   1: <body>
Copy after login
   2:     <div class="test">
Copy after login
   3:         <h3>所有分类</h3>
Copy after login
   4:         <div class="fenlei">
Copy after login
   5:             <h4>精美包包</h4>
Copy after login
   6:             <ul>
Copy after login
   7:                 <li>双肩包</li>
Copy after login
   8:                 <li style="margin-left:40px;">手提包</li>
Copy after login
   9:                 <li>女包</li>
Copy after login
  10:                 <li style="margin-left:57px;">男包</li>
Copy after login
  11:             </ul>
Copy after login
  12:         </div>
Copy after login
  13:         <div class="fenlei">
Copy after login
  14:             <h4>时尚手表</h4>
Copy after login
  15:             <ul>
Copy after login
  16:                 <li>充电器</li>
Copy after login
  17:                 <li style="margin-left:40px;">男表</li>
Copy after login
  18:                 <li>女表</li>
Copy after login
  19:                 <li style="margin-left:57px;">情侣表</li>
Copy after login
  20:             </ul>
Copy after login
  21:         </div>
Copy after login
  22:         <div class="fenlei">
Copy after login
  23:             <h4>时尚化妆品</h4>
Copy after login
  24:             <ul>
Copy after login
  25:                 <li>润肤霜</li>
Copy after login
  26:                 <li style="margin-left:40px;">面膜</li>
Copy after login
  27:                 <li>彩妆用品</li>
Copy after login
  28:             </ul>
Copy after login
  29:         </div>
Copy after login
  30:         <div class="fenlei">
Copy after login
  31:             <h4>潮流卫衣</h4>
Copy after login
  32:             <ul>
Copy after login
  33:                 <li>男士卫衣</li>
Copy after login
  34:                 <li style="margin-left:30px;">女士卫衣</li>
Copy after login
  35:                 <li>进口卫衣</li>
Copy after login
  36:             </ul>
Copy after login
  37:         </div>
Copy after login
  38:     </div>
Copy after login
  39: </body>
Copy after login

css:

   1: *
Copy after login
   2: {
Copy after login
   3:     margin: 0 auto;
Copy after login
   4: }
Copy after login
   5: .test
Copy after login
   6: {
Copy after login
   7:     width: 200px;
Copy after login
   8:     height: 350px;
Copy after login
   9:     border: 1px solid red;
Copy after login
  10: }
Copy after login
  11: h3
Copy after login
  12: {
Copy after login
  13:     background-color: #B90101;
Copy after login
  14:     padding: 5px;
Copy after login
  15:     color: white;
Copy after login
  16: }
Copy after login
  17: .fenlei
Copy after login
  18: {
Copy after login
  19:     border-bottom: 1px solid #ccc;
Copy after login
  20:     width: 190px;
Copy after login
  21:     margin-top: 5px;
Copy after login
  22:     margin-left: 5px;
Copy after login
  23:     float: left;
Copy after login
  24: }
Copy after login
  25: .fenlei ul
Copy after login
  26: {
Copy after login
  27:     position: relative;
Copy after login
  28:     margin-left: -30px;
Copy after login
  29:     float: left;
Copy after login
  30: }
Copy after login
  31: .fenlei li
Copy after login
  32: {
Copy after login
  33:     float: left;
Copy after login
  34:     text-align: left;
Copy after login
  35:     margin-left: 20px;
Copy after login
  36:     margin-top: 5px;
Copy after login
  37: }
Copy after login

The effect is as shown:

Demo address: http://jsfiddle.net /Web_Code/yhLnj7gh/embedded/result/

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template