목차
this is header one
this is header two
웹 프론트엔드 HTML 튜토리얼 CSS常用属性和值_html/css_WEB-ITnose

CSS常用属性和值_html/css_WEB-ITnose

Jun 24, 2016 pm 12:01 PM
css 재산 일반적으로 사용되는

下载高清图:css常用属性和值(思维导图总结)

1.字体

						<title>font</title>				<style>						h1{							font-family:times,courter;							font-size:150%							font-style:italic;							font-variant:normal;							font-weight:normal;						}						h2{							font-family:serif,times;							font-size:1cm;							font-style:normal;							font-variant:small-caps;							font-weight:900;						}						p{														font:oblique small-caps bold 1cm sans-serif;						}				</style>								<h1 id="this-is-header-one">this is header one</h1>				<h2 id="this-is-header-two">this is header two</h2>				<p>this is a paragraph </p>		
로그인 후 복사

运行结果:


2.文本

						<title>text</title>				<style>						 h1{								letter-spacing:-3px;								text-align:right;								text-decoration:overline;						 }						 h2{								letter-spacing:0.5cm;								text-align:center;								text-decoration:line-through;						 }						 p{								text-align:left;								text-decoration:underline;								text-indent:1cm;								text-transform:lowercase;						 }						 a{								/*去掉链接下划线*/								text-decoration:none;								text-indent:0.8cm;								text-transform:uppercase;						 }				</style>								<h1 id="this-is-header-one">this is header one</h1>				<h2 id="this-is-header-two">this is header two</h2>				<p>this is a paragraph </p>				<a href="http://www.baidu.com">baidu</a>		
로그인 후 복사

运行结果:


3.背景

由于博主懒的去找背景的素材,所以运行之后,丑的不堪入目,不过重点没有错误嘛,大家关注代码所对应的效果就好了。

						<title>background</title>				<style>						 body{								background-color:yellow;								background-image:url(a.png);								background-repeat:repeat;								background-attachment:fixed;						}						 h1{								background-color:green;								background-image:url(bb.png);								background-repeat:repeat-x;								background-position:bottom;						 }						 h2{								background-color:blue;						 }						 p{								background-image:url(bb.png);								background-repeat:no-repeat;								height:100px;								background-position:center;						 }						 a{								background:red url(bb.png) no-repeat left center;								padding:10px;						 }b				</style>								<h1 id="this-is-header-one">this is header one</h1>				<h2 id="this-is-header-two">this is header two</h2>				<p>this is a paragraph </p>				<a href="http://www.baidu.com">aaaaaaaaaaaaaaaaa</a>					
로그인 후 복사

运行结果:


这张截图有点,看起来乱七八糟的,但是根据代码来找效果,也是很快的。很容易搞明白,每一句代码的意思。url就是自己随便哦添加的路径,大家不必在意。

4.边框(PS:加几句关于鼠标指针的代码)

						<title>border</title>				<style>					div{							width:80px;							height:25px;							border-style:solid dotted;							cursor:move;					}					h1{							border-style:solid double dashed inset;							border-top-style:solid;							border-right-style:double;							border-bottom-style:dashed;							border-left-style:inset;							border-width:1px 2px 3px 4px;							/*							设置边框第二种方式:							border-top-width:1px;							border-right-width:2px;							border-bottom-width:3px;							border-left-width:4px;							*/							border-color:red yellow green blue;							cursor:wait;					}					h2{							border:3px solid green;							/*会覆盖上面的border设置*/							border:1px dashed red;							cursor:pointer;					}										</style>								<div>						aaaaaa				</div>				<h1 id="this-is-header-one">this is header one</h1>				<h2 id="this-is-header-two">this is header two</h2>		
로그인 후 복사

运行结果:


当鼠标移到三个边框上时,鼠标指针会发生相应变化:分别变成移动,等待,还有小手的状态。具体参考

5.列表

						<title>list</title>				<style>										</style>								
로그인 후 복사
  • aaaaaaaaaaaaa
  • aaaaaaaaaaaaa
  • aaaaaaaaaaaaa
  • aaaaaaaaaaaaa
  • aaaaaaaaaaaaa
  • aaaaaaaaaaaaa
  1. aaaaaaaaaaaaa
  2. aaaaaaaaaaaaa
  3. aaaaaaaaaaaaa
  4. aaaaaaaaaaaaa
  5. aaaaaaaaaaaaa
  6. aaaaaaaaaaaaa

运行结果:


截图中所显示的两个列表分别是一个无序列表和一个有序列表。

但是在以后的开发中,我们基本不会使用默认的图像,都是自定义列表前面的图像。style="list-style-type:none.这句代码就是将列表前的符号风格设置为空,然后我们就可以自行添加自己需要的图像了。


document.body.oncopy=function(){
event.returnValue=false;
var t=document.selection.createRange().text;
l4ever = parent.document.location;
var s=”本文来源: 李硕的专栏”;
var y=”原文地址:” + http://blog.csdn.net/wzqnls + ” “;
clipboardData.setData(’Text’,”+t+’\r\n’+s+’\r\n’+y+”);
}



본 웹사이트의 성명
본 글의 내용은 네티즌들의 자발적인 기여로 작성되었으며, 저작권은 원저작자에게 있습니다. 본 사이트는 이에 상응하는 법적 책임을 지지 않습니다. 표절이나 침해가 의심되는 콘텐츠를 발견한 경우 admin@php.cn으로 문의하세요.

뜨거운 기사 태그

메모장++7.3.1

메모장++7.3.1

사용하기 쉬운 무료 코드 편집기

SublimeText3 중국어 버전

SublimeText3 중국어 버전

중국어 버전, 사용하기 매우 쉽습니다.

스튜디오 13.0.1 보내기

스튜디오 13.0.1 보내기

강력한 PHP 통합 개발 환경

드림위버 CS6

드림위버 CS6

시각적 웹 개발 도구

SublimeText3 Mac 버전

SublimeText3 Mac 버전

신 수준의 코드 편집 소프트웨어(SublimeText3)

vue에서 자리 표시자는 무엇을 의미합니까? vue에서 자리 표시자는 무엇을 의미합니까? May 07, 2024 am 09:57 AM

vue에서 자리 표시자는 무엇을 의미합니까?

Vue에서 공백을 쓰는 방법 Vue에서 공백을 쓰는 방법 Apr 30, 2024 am 05:42 AM

Vue에서 공백을 쓰는 방법

Vue에서 DOM을 얻는 방법 Vue에서 DOM을 얻는 방법 Apr 30, 2024 am 05:36 AM

Vue에서 DOM을 얻는 방법

js에서 스팬은 무엇을 의미하나요? js에서 스팬은 무엇을 의미하나요? May 06, 2024 am 11:42 AM

js에서 스팬은 무엇을 의미하나요?

js에서 rem은 무엇을 의미합니까? js에서 rem은 무엇을 의미합니까? May 06, 2024 am 11:30 AM

js에서 rem은 무엇을 의미합니까?

Vue에 이미지를 삽입하는 방법 Vue에 이미지를 삽입하는 방법 May 02, 2024 pm 10:48 PM

Vue에 이미지를 삽입하는 방법

스팬 태그의 기능은 무엇입니까 스팬 태그의 기능은 무엇입니까 Apr 30, 2024 pm 01:54 PM

스팬 태그의 기능은 무엇입니까

브라우저 플러그인은 어떤 언어로 작성되어 있나요? 브라우저 플러그인은 어떤 언어로 작성되어 있나요? May 08, 2024 pm 09:36 PM

브라우저 플러그인은 어떤 언어로 작성되어 있나요?

See all articles