静态网页制作练习


HTML和CSS练习对象网页:https://www.dafanshu.com/kpyx/9985.html

一、分析布局

布局分析如下
在这里插入图片描述

二、创建html文件,默认设置

<head>
		<style type="text/css">
			body, div, dl, dt, dd, ul, ol, li, h1, h2, h3, h4, h5, h6, pre, code, form, fieldset, legend, input, textarea, p, blockquote, th, td{
				    margin: 0;
    				padding: 0;
    				font-family: '微软雅黑';
    				list-style-type: none;
			}
			body {
    		background: #f5f5f5;
    		display: block;
			}
			div {
				display: block;
				display: flex;
			}
		</style>
		
	</head>

​## 三、header区域
样式

/*header区域*/
			.header {
		    background: #FFF;
		    position: relative;
		    z-index: 999;
		    list-style-type: none;
		    margin: auto;
			}

html

	<div class="header">
    <div class="topbar">
        <div class="w1200">
            <ul class="toplinks">
                <li>大番薯,专业安全免费的软件下载网站</li>
            </ul>
            <div class="snav">
                <ul>
                </ul>
            </div>
        </div>
    </div>
    <div class="header-main w1200">
        <div class="logo"><a href="https://www.dafanshu.com/" title="大番薯" target="_self"></div>
        <div class="top-search" target="_blank">
            <input type="text" name="q" class="top-input msearchword" placeholder="请输入游戏名称">
            <input type="button" class="topsobar" onclick="funMSearch()" value="搜索">
        </div>
    </div>
    <div class="navbar">
        <ul class="nav">
            <li class=""><a href="#" target="_self">首页</a></li>
            <li class="active">
                <a href="#">手机游戏</a>
            </li>
            <li class="#">
                <a href="#">手机应用</a>
            </li>
            <li class="#">
                <a href="#">电脑软件</a>
            </li>
            <li><a href="#">专题合集</a></li>
            <li><a href="#">电脑常识</a></li>
            <li><a href="#">软件问题</a></li>
        </ul>
    </div>
</div>

未完待续

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值