CSS05 背景色と余白
<head>
<meta http-equiv="Content-Type" content="text/html;charset=UTF-8"
/><style type="text/css">
body{
padding:3em;
margin:0px;
}
h2{
font-size:1.1em;
color:white;
background-color:#3914af;
margin:0px;
padding:1em;
}
p{
background-color:#dccbff;
margin:0px;
padding:1em;
}
</style>
</head>
CSS06 背景画像を設定
<head>
<meta http-equiv="Content-Type" content="text/html;charset=UTF-8" />
<style type="text/css">
body{
background-image:url(images/01.jpeg)
}
</style>
</head>
CSS07 背景画像を設定(水平方向に繰り返し)
<head>
<meta http-equiv="Content-Type" content="text/html;charset=UTF-8" />
<style type="text/css">
body{
background-image:url(images/02.jpeg);
background-repeat: repeat-x;
}
h1{
color:#CD5C5C;
font-size:6.5em;
}
</style>
</head>
CSS08 背景画面を設定(水平方向に繰り返し)
<head>
<meta http-equiv="Content-Type" content="text/html;charset=UTF-8" />
<title>CSS08</title>
<style type="text/css">
body{
background-image:url(images/03.jpeg);
background-repeat:repeat-y;
}
h1{
color:white;
}
</style>
</head>
CSS09 背景画像と枠線
<head>
<meta http-equiv="Content-Type" content="text/html;charset=UTF-8" />
<title>CSS09</title>
<style type="text/css">
body{
background-color:;
background-image:url(images/04.jpeg);
background-repeat:repeat-y;
}
h1{
margin:24px 82px;
border-bottom:dotted 3px #800000;
border-bottom-style:dashed;
color:#B22222;
}
p{
color:#444444;
margin:0px 78px;
</style>
</head>
CSS10 背景画像(繰り返さない)
<head>
<meta http-equiv="Content-Type" content="text/html;charset=UTF-8" />
<title>CSS10</title>
<style type="text/css">
body{
background-image:url(images/06.gif);
background-repeat:no-repeat;
}
h1{
font-family:serif;
margin: 45px 150px;
}
p{
font-size:1em;
font-family:cursive;
margin: 0px 150px;
}
</style>
</head>