浮动练习(3)

##每台电脑分辨率不同,数值高度宽度需要自己调,仅供参考

<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title></title>

<style>

div{

display: flex;

align-items: center;

justify-content: center;

}

.main{

width: 100%;

font-size: 24px;

/*text-align: center;*/

display: block;

}

.main .banner{

widows: 100%;

height: 100px;

/*background: red;*/

}

.main .banner .logo{

background: gainsboro;

width: 20%;

height: 100%;

float: left;

}

.main .banner .banner1{

background: gainsboro;

width: 58%;

height: 100%;

float: left;

margin: 0px 19px;

}

.main .banner .banner2{

background: gainsboro;

width: 20%;

height: 100%;

float: left;

}

.main .menu{

width: 100%;

height: 43px;

background: gainsboro;

margin: 16px 0px;

}

.main .container{

display: block;

height: 680px;

}

.main .container .lanmu{

width: 653px;

/*background: gainsboro;*/

height:100%;

float: left;

margin-right: 15px;

display: block;

}

.main .container .lanmu2{

width: 457px;

/*background: gainsboro;*/

height:100%;

float: left;

display: block;

}

.lanmu .lanmu3{

width: 655px;

height: 300px;

border: 2px solid black;

}

.lanmu .lanmu4{

width: 309px;

height: 355px;

border: 2px solid black;

margin: 15px 15px 0px 0px;

display: inline-block;

float: left;

}

.lanmu .lanmu5{

margin-right: 0px;

}

.lanmu2 .lanmu6{

width: 450px;

height: 212px;

border: 2px solid black;

margin-bottom: 16px;

}

.foot{

width: 100%;

height: 80px;

background: gainsboro;

margin: 16px 0px;

}

</style>

</head>
<body>

<div class="main">

<div class="banner">

<div class="logo">logo</div>

<div class="banner1">banner1</div>

<div class="banner2">banner2</div>

</div>

<div class="menu">菜单</div>

<div class="container">

<div class="lanmu">

<div class="lanmu3">栏目一</div>

<div class="lanmu4">栏目三</div>

<div class="lanmu4 lanmu5">栏目四</div>

</div>

<div class="lanmu">

<div class="lanmu3">栏目二</div>

<div class="lanmu4">栏目五</div>

<div class="lanmu4 lanmu5">栏目六</div>

</div>

<div class="lanmu2">

<div class="lanmu6">栏目七</div>

<div class="lanmu6">栏目八</div>

<div class="lanmu6">栏目九</div>

</div>

</div>

<div class="foot">页脚</div>

</div>
</body>
</html>

相关推荐
xxwl5858 小时前
HTML 小总结:从骨架到枝叶,系统掌握网页结构
前端·html
用户0595401744620 小时前
LLM对话记忆测试踩坑实录:手工回归30分钟,自动化后2分钟发现3个隐藏Bug
前端·css
blns_yxl1 天前
购物车(HTML+JS+CSS)
html
Web - Anonymous1 天前
CSS+Vue3 + TS + Setup 10种生产级可视化循环动效合集(大屏高端交互、开箱复用)-附完整示例
前端·css·信息可视化
blns_yxl1 天前
正则驱动实时表单验证(HTML+CSS+JS+正则)
javascript·css·html
大白要努力!1 天前
纯前端实现 PDF 加水印工具 —— 零后端、支持中文、实时预览
前端·pdf·html
蜡台1 天前
使用 uni-popup 实现数据选择器Data-Picker
前端·javascript·html·uniapp·uni-popup·data-picker
blns_yxl1 天前
Promise封装Fetch + 重试机制(HTML+JS)
前端·javascript·html
杨超越luckly2 天前
Agent应用指南:13年与13线——武汉地铁进化史
数据分析·html·agent·可视化·地铁客流
思码梁田2 天前
CSS cursor 属性全解析:从“小手“开始,玩转鼠标光标
前端·css·计算机外设·cursor·pointer