Home>Article>Daily Programming> Three ways to add CSS

Three ways to add CSS

autoload
autoload Original
2021-03-31 11:54:17 6364browse

Three ways to add CSS

CSS style is an important part of the front-end web page production, so how to use and introduce CSS style is particularly prominent. This article mainly introduces three ways to use CSS style.

1. Use external styles:

  

The style.css file is as follows

h1 { color: blue; background-color: yellow; border: 1px solid black; } p { color: red; }

When filling in the href Is the location of the css file

2. Use internal styles:

      Document 

php.cn

3. Use inline styles (Inline style):

 

Hello World!

Test

Recommended: "2021 CSS Interview Questions Summary (Latest)"

The above is the detailed content of Three ways to add CSS. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn