Home Web Front-end CSS Tutorial div combined with css layout bbs homepage (div css layout entry)_Experience exchange

div combined with css layout bbs homepage (div css layout entry)_Experience exchange

May 16, 2016 pm 12:04 PM
layout

I divided the forum homepage into header area, information area, content area, and footer area. First, use a large div to include these. The main reason is to facilitate the overall adjustment of the page. For example, if you want to adjust it to wide screen or narrow screen, you only need to set this large div.
Post the code first for friends to use for debugging.
css:

Copy code The code is as follows:

/* CSS Document */
body{
background-color:#F5F5F5;
margin:0;
padding:0;
font-family : "Lucida Grande", Verdana, Lucida, Arial, Helvetica, , sans-serif;
font-size:12px;
}
.pagehoder{
width:100%;
margin:auto;
background-color:#2662DF;
border-left:2px solid #7197D7;
border-rigth:2px solid #7197D7;
border-bottom:2px solid #7197D7;
}
.header{
border-top :2px solid #7197D7;
height:60px;
background-color: #B1C3D9;
}

.logo{
background:url(../images/logo. png) no-repeat ;
width:200px;
height:60px;
float:left;
}
.img{
background:url(../images/images1 .jpg) repeat-x ;
height:60px;
}
.navigate {
padding-left:20px;
background-color:#F3F8FE;
height:10px;
}
.navigate li{
float:left;
}
.navigate li a{
margin-left:2px;
padding-top:3px;
padding-bottom:3px;
text-align:center;
display:block;
text-decoration:none;
width:70px;
height:10px;
background -color:#ececec;
}
.navigate li a:hover{
color:#ffffff;
background-color:#bbbbbb;
}
.notice{
background-color:#ffffff;
height:20px;
}
.content{
background-color:#0000FF;
height:400px;
}
. contentHead{
text-align:center;
padding-top:5px;
padding-bottom:0px;
height:20px;
background-color:#71A3CC;
}
.f1{
width:60%;
float:left;
background-color:#71A3CC;
}
.f2{
width:12%; float:left;
background-color:#71A3CC;
}
.f3{
width:12%;
float:left;
background-color:#71A3CC ;
}
.f4{
width:15%;
background-color:#71A3CC;
}

.typeHolder{
width:100%;
background-color:#D9DBE4;
}
.type{
width:60%;
float:left;
}
.boardHolder{
text- align:center;
width:100%;
background-color:#FFFFFF;
}
.boardName{
width:60%;
float:left;
}
.subject{
width:12%;
float:left;
background-color:#F7F7F8;
}
.article{
width:12%;
float:left;
background-color:#F7F7F8;
}
.last{
width:15%;
background-color:#F7F7F8;
} .msg{
background-color:#FAFAFA;
height:60px;
}
.footer{
background-color:#99CC33;
height:20px; text-align:center;
}
.
html:
Copy code The code is as follows:







sclBBS Home Page








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 Article Tags

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)

Windows 11: The easy way to import and export start layouts Windows 11: The easy way to import and export start layouts Aug 22, 2023 am 10:13 AM

Windows 11: The easy way to import and export start layouts

How to save desktop icon position layout in Windows 11 How to save desktop icon position layout in Windows 11 Aug 23, 2023 pm 09:53 PM

How to save desktop icon position layout in Windows 11

Guide to solving misalignment of WordPress web pages Guide to solving misalignment of WordPress web pages Mar 05, 2024 pm 01:12 PM

Guide to solving misalignment of WordPress web pages

How to create a responsive carousel layout using HTML and CSS How to create a responsive carousel layout using HTML and CSS Oct 20, 2023 pm 04:24 PM

How to create a responsive carousel layout using HTML and CSS

Robot ETF (562500) may usher in a good layout opportunity because it has pulled back for 3 consecutive days! Robot ETF (562500) may usher in a good layout opportunity because it has pulled back for 3 consecutive days! Dec 01, 2023 pm 04:01 PM

Robot ETF (562500) may usher in a good layout opportunity because it has pulled back for 3 consecutive days!

Flexible application skills of position attribute in H5 Flexible application skills of position attribute in H5 Dec 27, 2023 pm 01:05 PM

Flexible application skills of position attribute in H5

Introducing the window arrangement method in win7 Introducing the window arrangement method in win7 Dec 26, 2023 pm 04:37 PM

Introducing the window arrangement method in win7

Windows 11 keeps adding keyboard layouts: 4 tested solutions Windows 11 keeps adding keyboard layouts: 4 tested solutions Dec 14, 2023 pm 05:49 PM

Windows 11 keeps adding keyboard layouts: 4 tested solutions

See all articles