2016 08 10 css选择器练习——常用属性

作业一:

/*设置字间距*/
letter-spacing:10px;
/*
	设置中划线
	text-decoration是用来设置划线的,常用的还有uderline和none
*/
text-decoration:line-through;
/*加粗*/
font-weight:bold;


作业二:

/*设置背景图片*/
background-image:url('01.png');

/*
	设置div边框
	注意:这里必须要设置白色边框,这样下面的margin-top和margin-left	才会有效,否则背景图片会和后来的边框一起移动。
*/
border:1px solid white;

/*内边距*/
padding:10px;

/*外边距(与div的距离)*/
margin-top:15px;
margin-left:20px;

作业三:

/*斜体,另一属性为italic*/
font-style:oblique;

/*字行高*/
line-height:50px;

/*div的边框*/
border:3px solid black;

作业七:

/*table中*/

/*单元格间距*/
border-collapse:collapse;

/*单元格宽度*/
width:650px;

/*表格居中*/
margin: 0 auto;

/*
另外需要显示表内线则需要每行表中都插入border
*/
border:1px solid #70AA39;

/*背景色*/
background-color:#A7C942;




你可能感兴趣的:(php暑假班所学)