Home Web Front-end HTML Tutorial 商城导航代码_html/css_WEB-ITnose

商城导航代码_html/css_WEB-ITnose

Jun 24, 2016 am 11:38 AM

  一个css写的商城导航效果 

<!DOCTYPE html><html lang="en"><head>    <meta charset="UTF-8">    <title>商城分类导航</title>    <style type="text/css">       body        {            padding: 0;            font-size: 10pt;        }        .topmenu        {            display: block;            width: 220px;            border: 2px solid #e4393c;            margin: 0;            padding: 0;        }        .toptitle        {            height: 40px;            line-height: 40px;            text-align: left;            font-size: 11pt;            font-weight: bold;            color: White;            background: #e4393c;            padding-left: 20px;        }        .topmenu li        {            height: 30px;            line-height: 30px;            font-size: 11pt;            list-style-type: none;            text-align: left;            padding-left: 8px;            z-index: 3;            background-image:url(http://img.mukewang.com/5411027300014f0200220030.jpg);            background-repeat:no-repeat;            background-position:right;        }        .topmenu li:hover           {            border:1px solid #DDD;            border-right:0;            box-shadow: 0 0 8px #DDD;            -moz-box-shadow:0 0 8px #DDD;            -webkit-box-shadow:0 0 8px #DDD;            background-image:none;            }        .topmenu li a        {            text-decoration: none;            color: #313131;        }        .topmenu li a:hover        {            text-decoration: underline;            font-weight: bold;            color: #e4393c;        }        .submenu        {            display: none;            width: 715px;            left: 220px;            position: absolute;            top: 40px;            border: 1px solid #DDD;            z-index: 4;            background: white;            box-shadow: 0 0 8px #DDD;            -moz-box-shadow: 0 0 8px #DDD;            -webkit-box-shadow: 0 0 8px #DDD;          }        .leftdiv        {            float:left;            width:490px;            margin:5px;        }        .rightdiv        {            float:left;            width:200px;            margin:5px;        }        .topmenu li:hover .submenu        {            display: block;        }        .topmenu li:hover span        {            background: white;            display: inline-block;            z-index: 20;            width: 20px;            height: 30px;            float: right;            position: relative;        }        .leftdiv dl        {            display:block;            border:-bottom:1px solid #EEE;            padding-bottom:6px;            overflow: hidden;        }        .leftdiv dl dt        {            display: block;            float:left;            width:60px;            text-align: right;            height:22px;            line-height: 22px;            padding-right:6px;        }        .leftdiv dl dt a        {            color:#e4393c;            font-weight: blod;            text-decoration: underline;            font-size:10pt;        }        .leftdiv dl dd        {            display: block;            overflow: hidden;        }        .leftdiv dl dd a        {            display: block;            float:left;            border-left:1px solid #DDD;            color:#737373;            font-size: 9px;            padding:0 8px;            height:14px;            line-height: 14px;            margin:4px 0;        }        .rightdiv dl dd        {            margin:3px 0;        }        .rightdiv dl dt        {            color:#e4393c;            font-weight: bold;            font-size:10pt;        }        .rightdiv dl dd a        {            font-size:9pt;            color:#737373;            line-height: 22px;        }        .rightdiv dl dd a:hover        {            color:#737373;            font-weight: normal;        }    </style></head><body>    <ul class="topmenu">        <div class="toptitle">            全部商品分类        </div>        <li>            <a href="#">图书、音像、数字商品</a><span></span>            <div class="submenu">                <div class="leftdiv">                <dl>                    <dt><a href="">电子书</a></dt>                    <dd>                        <a href="">免费</a><a href="">小说</a><a href="">励志与成功</a>                        <a href="">婚恋/两性</a><a href="#">文学</a><a href="#">经管</a> <a href="#">畅读VIP</a>                    </dd>                <dl >                    <dt><a href="#">生活</a></dt>                    <dd>                        <a href="#">家教与育儿</a> <a href="#">旅游/地图</a> <a href="#">烹饪/美食</a> <a href="#">时尚/美妆</a>                        <a href="#">家居</a> <a href="#">婚恋与两性</a> <a href="#">娱乐/休闲</a> <a href="#">健身与保健</a>                        <a href="#">动漫/幽默</a> <a href="#">体育/运动</a>                    </dd>                </dl>                </div>            <div class="rightdiv">                   <dl>                       <dd>                           <a href="http://sale.jd.com/act/1XDZ6ShE5M7tTrl.html">                               <img  src="/static/imghw/default1.png"  data-src="http://img30.360buyimg.com/erpVCAare/g16/M00/0B/1B/rBEbRlOCFcoIAAAAAAArMNB2tlkAACTlwDgVG8AACtI514.jpg"  class="lazy"                                      style="max-width:90%"  style="max-width:90%" title="\家电" alt="商城导航代码_html/css_WEB-ITnose" >                           </a>                       </dd>                   </dl>                   <dl>                       <dt>推荐品牌</dt>                       <dd>                           <a href="#">美的官方旗舰店</a>                       </dd>                       <dd>                           <a href="#">苏泊尔旗舰店</a>                       </dd>                     </dl>               </div>            </div>        </li>       <li>           <a href="#">家用电器</a>            <div class="submenu">                <div class="leftdiv">                <dl>                    <dt><a href="">大家电</a></dt>                    <dd>                        <a href="">平板电视</a>                        <a href="">空调</a>                        <a href="">冰箱</a>                        <a href="">洗衣机</a>                         <a href="#">扫地机器人</a>                         <a href="#">吸尘器</a>                         <a href="#">电话机</a>                         <a href="">家电配件</a>                         <a href="">家庭影院</a>                         <a href="">冷柜/冰吧</a>                         <a href="">洗衣机</a>                    </dd>                </dl>            </div>            </div>       </li>       <li><a href="#">手机、数码</a></li>        <li><a href="#">电脑、办公</a></li>        <li><a href="#">家居、家具、家装、厨具</a></li>        <li><a href="#">服饰内衣、珠宝首饰</a></li>        <li><a href="#">个护化妆</a></li>        <li><a href="#">鞋靴、箱包、钟表、奢侈品</a></li>        <li><a href="#">运动户外</a></li>        <li><a href="#">汽车用品</a></li>        <li><a href="#">母婴、玩具乐器</a></li>        <li><a href="#">食品饮料、酒类、生鲜</a></li>        <li><a href="#">营养保健</a></li>    </ul></body></html>
Copy after login

Copy after login

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

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

Video Face Swap

Video Face Swap

Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Tools

Notepad++7.3.1

Notepad++7.3.1

Easy-to-use and free code editor

SublimeText3 Chinese version

SublimeText3 Chinese version

Chinese version, very easy to use

Zend Studio 13.0.1

Zend Studio 13.0.1

Powerful PHP integrated development environment

Dreamweaver CS6

Dreamweaver CS6

Visual web development tools

SublimeText3 Mac version

SublimeText3 Mac version

God-level code editing software (SublimeText3)

Is HTML easy to learn for beginners? Is HTML easy to learn for beginners? Apr 07, 2025 am 12:11 AM

HTML is suitable for beginners because it is simple and easy to learn and can quickly see results. 1) The learning curve of HTML is smooth and easy to get started. 2) Just master the basic tags to start creating web pages. 3) High flexibility and can be used in combination with CSS and JavaScript. 4) Rich learning resources and modern tools support the learning process.

The Roles of HTML, CSS, and JavaScript: Core Responsibilities The Roles of HTML, CSS, and JavaScript: Core Responsibilities Apr 08, 2025 pm 07:05 PM

HTML defines the web structure, CSS is responsible for style and layout, and JavaScript gives dynamic interaction. The three perform their duties in web development and jointly build a colorful website.

Understanding HTML, CSS, and JavaScript: A Beginner's Guide Understanding HTML, CSS, and JavaScript: A Beginner's Guide Apr 12, 2025 am 12:02 AM

WebdevelopmentreliesonHTML,CSS,andJavaScript:1)HTMLstructurescontent,2)CSSstylesit,and3)JavaScriptaddsinteractivity,formingthebasisofmodernwebexperiences.

Gitee Pages static website deployment failed: How to troubleshoot and resolve single file 404 errors? Gitee Pages static website deployment failed: How to troubleshoot and resolve single file 404 errors? Apr 04, 2025 pm 11:54 PM

GiteePages static website deployment failed: 404 error troubleshooting and resolution when using Gitee...

What is an example of a starting tag in HTML? What is an example of a starting tag in HTML? Apr 06, 2025 am 12:04 AM

AnexampleofastartingtaginHTMLis,whichbeginsaparagraph.StartingtagsareessentialinHTMLastheyinitiateelements,definetheirtypes,andarecrucialforstructuringwebpagesandconstructingtheDOM.

How to use CSS3 and JavaScript to achieve the effect of scattering and enlarging the surrounding pictures after clicking? How to use CSS3 and JavaScript to achieve the effect of scattering and enlarging the surrounding pictures after clicking? Apr 05, 2025 am 06:15 AM

To achieve the effect of scattering and enlarging the surrounding images after clicking on the image, many web designs need to achieve an interactive effect: click on a certain image to make the surrounding...

HTML, CSS, and JavaScript: Essential Tools for Web Developers HTML, CSS, and JavaScript: Essential Tools for Web Developers Apr 09, 2025 am 12:12 AM

HTML, CSS and JavaScript are the three pillars of web development. 1. HTML defines the web page structure and uses tags such as, etc. 2. CSS controls the web page style, using selectors and attributes such as color, font-size, etc. 3. JavaScript realizes dynamic effects and interaction, through event monitoring and DOM operations.

How to distinguish between closing a browser tab and closing the entire browser using JavaScript? How to distinguish between closing a browser tab and closing the entire browser using JavaScript? Apr 04, 2025 pm 10:21 PM

How to distinguish between closing tabs and closing entire browser using JavaScript on your browser? During the daily use of the browser, users may...

See all articles