HTML基本样式

1、标签:

<style>:样式定义

<link>:资源引用

2、属性

rel=”stylesheet”:外部样式表

type=”text/css”:引入文档的类型

magin-left:边距

3、三种样式表插入方法:

外部样式表:

               <link rel=”stylesheet” type=”text/css” href=”mystyle.css”>

内部样式表:

扫描二维码关注公众号,回复: 3048774 查看本文章

               <style type=”text/css”>

               body{background-color:red}

               p{margin-left:20px}

               </style>

       内联样式表:

                     <p style=”color:red”>

猜你喜欢

转载自www.cnblogs.com/sun-yanglu/p/9583793.html