Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to set the first line indentation in html

2025-01-16 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >

Share

Shulou(Shulou.com)05/31 Report--

This article mainly explains "how to set the first line indentation in html". The content in the article is simple and clear, and it is easy to learn and understand. Please follow the editor's train of thought to study and learn "how to set the first line indent in html".

In HTML, you can use the text-indent attribute to set the first line indentation, simply by setting "text-indent: indent value" for the text element. The text-indent attribute specifies the indentation of the first line of text in the text block; negative values are allowed, and if negative values are used, the first line is indented to the left.

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

Indent 2 characters. P {text-indent: 2em;} kindness is your nature, beauty is your nature, cleverness is your advantage, virtue is your capital, gentleness is your mark, sincerity is your character, International Working Women's Day, I wish you happiness, youth and beauty all your life!

Warm March, spring return to the earth, sunny, green grass, organize your thoughts, pick up your mood, feel a good life, taste International Working Women's Day wonderful, women want to be nice to themselves, happy holidays, I wish you forever young!

Effect:

The text-indent attribute specifies the indentation of the first line of text in a text block.

Note: negative values are allowed. If you use a negative value, the first line is indented to the left.

Note: prior to CSS 2.1, text-indent always inherited calculated values, not declared values.

Thank you for your reading, the above is the content of "how to set the first line indentation in html". After the study of this article, I believe you have a deeper understanding of how to set the first line indentation in html, and the specific use needs to be verified in practice. Here is, the editor will push for you more related knowledge points of the article, welcome to follow!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Internet Technology

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report