我知道我可以使用<br>进行简单的换行。我也知道可以通过向<p style="margin-left:12px">添加样式来添加缩进。

现在我有一个问题,就是<p>中断了两行,几乎就像插入<br><br>一样。

我无法将样式应用于<br>,也无法弄清楚如何防止<p>出现双行中断。

是否有不折线之类的元素?无论我添加什么元素来应用样式,它们都有双换行符,例如div

模样

我想要的是

some text
  some other text
    even more text


我能达到的目标

这是我在<p>样式中使用三个margin-left的结果:

some text

  some other text

    even more text


这是我可以使用br实现的功能:

some text
some other text
even more text

最佳答案

尝试将span元素与float: left; clear: both;一起使用,然后使用所需的任何空白边距。

09-25 17:02
查看更多