1 在标签中添加声明
style="" <input type="text" placeholder="手机号码" style="">声明位置不分先后; 与其他关键字之间用空格隔开。 关键字与标签名要用空格隔开。
<p style=""></p>2 在引号之间添加样式 设置标签字体大小和颜色:
<p style="font-size:大小;color:颜色"></p>在CSS中,样式由属性和值组成。 字体大小 设置格式:font-size:36px;
font-size-->字体的大小 36px-->字体大小的尺寸两组以上属性时,结尾分号可省略,但不规范。 字体加粗 设置格式:font-weight:100; 设置粗细可以是数字也可以是英文。
颜色 设置方式: 1.英文字母形式 color:black; 2.十六进制颜色 color:#DAE8FC; 3.rgb形式 color:rgb(253,217,106); 4.rgba形式 color:rgba(253,217,106,1.0);
1.多数情况下使用十六进制; 2.调试时可以用英文字母形式; 3.用rgba形式设置文字透明度或背景透明度。
<h3 style="color:#ff9a9e;font-weight:700;font-size: 24px;">UIzards</h3>文字居中/居左/居右
text-align:center;文字居中对齐text-align:left;文字左对齐text-align:right;文字右对齐行高 设置格式:line-height:30px; 作用①:改变行距
<p>We understand every aspect of project and we put a great amount of time in understanding the project.</p> <p style="line-height:32px;">We understand every aspect of project and we put a great amount of time in understanding the project.</p>作用②:是文字上下居中
<button style="width: 120px;height:50px;text-align: center;line-height:50px;color:white;font-size: 18px;"> 提交 </button>字间距
英文的字间距是字母之间的距离,单词之间的距离不属于字间距中文是汉字之间的距离设置格式:letter-spacing:30px;
字体 设置格式:关键字+值
font-family: sans-serif;多设置几个字体:
font-family: "Goudy Bookletter 1911", sans-serif,Gill Sans Extrabold;