搜索
  • 登录
  • 注册
密码重置成功

关注您感兴趣的项目并了解有关它们的最新消息

如何缩进文本

实例解析:

text-indent属性用于指定文本块中首行文本的缩进; 允许使用负值,如果值是负数,将第一行左缩进。

可以设置以下的值:

 ● length:定义固定的缩进。默认值:0。    

 ● %:定义基于父元素宽度的百分比的缩进。    

新建文件
<!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>php中文网(php.cn)</title> <style> p {text-indent:50px;} </style> </head> <body> <p>In my younger and more vulnerable years my father gave me some advice that I've been turning over in my mind ever since. 'Whenever you feel like criticizing anyone,' he told me, 'just remember that all the people in this world haven't had the advantages that you've had.'</p> </body> </html>
重置代码
自动运行
提交
预览 Clear