官术网_书友最值得收藏!

Chapter 1. HTML Elements

HyperText Markup Language (HTML) is a language that annotates text. Annotation of text is done using elements. Using the following p element, as an example, we will see how to use HTML:

<p>This is an example</p>

HTML elements also have attributes that will modify how they are rendered or interpreted. Attributes are added inside of the starting tag. Here is the class attribute in a p element:

<p class="example">This is an example</p>

There have been multiple specifications of HTML so far, but we will just look at the most commonly used and important elements of HTML5. HTML5 is the latest official specification, so we will be as future-proof as possible at the time of writing this book. You will want to follow the specifications of HTML as closely as possible. Most browsers are very forgiving and will render your HTML, but when you go beyond the specifications, you can and will run into strange rendering issues.

Note

All HTML elements will have global attributes. The attributes listed for each element in the sections that follow are the attributes beyond the global attributes.

主站蜘蛛池模板: 望奎县| 华亭县| 吉木萨尔县| 固原市| 海晏县| 宾阳县| 会昌县| 绩溪县| 特克斯县| 大埔区| 嘉兴市| 库车县| 毕节市| 金华市| 且末县| 象山县| 米脂县| 滁州市| 克东县| 布尔津县| 苏州市| 冷水江市| 新河县| 高密市| 呼图壁县| 卓资县| 仪陇县| 都兰县| 清原| 收藏| 闸北区| 阿城市| 昌图县| 丰原市| 乌拉特后旗| 临朐县| 庆安县| 石景山区| 健康| 乌什县| 扶沟县|