text-indent: ***;
Browser |
|
---|
The text-indent property indents the first line of text.
p {
text-indent: 1em;
}
Property | Value | Explanation |
---|---|---|
text-indent | length or % | the indentation size |
The default is "0".
Example
<html>
<head>
<title>TAG index</title>
<style type="text/css">
p {
width: 40%;
text-indent: 1em;
}
</style>
</head>
<body>
<p>
The first paragraph. This is example text. some text ...
</p>
<p>
The second paragraph. This is example text. some text ...
</p>
</body>
</html>
- Output
-
The first paragraph. This is example text. some text some text some text some text some text some text some text some text some text some text
The second paragraph. This is example text. some text some text some text some text some text some text some text some text some text some text