Home >Web Front-end >CSS Tutorial >How to set all tags in css

How to set all tags in css

醉折花枝作酒筹
醉折花枝作酒筹Original
2021-07-15 09:55:024266browse

Setting method: 1. List all tags, the syntax is "body,ol,ul,h1,h2,h3,h4,h5,h6,p,th...{Attribute: attribute value; }"; 2. Use * to set, and the syntax format is "*{attribute:attribute value;}".

How to set all tags in css

The operating environment of this tutorial: Windows 7 system, CSS3&&HTML5 version, Dell G3 computer.

First method:

body,ol,ul,h1,h2,h3,h4,h5,h6,p,th,td,dl,dd,form,fieldset,legend,input,textarea,select{
margin:0;
padding:0
}

Second method:

*{
margin:0;
padding:0
}

Recommended learning: css video tutorial

The above is the detailed content of How to set all tags in 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