我有一些文本需要對齊到左側,但保持相同的行格式,就好像它居中。這是一個例子。如何讓文本左對齊但格式化,就好像它居中
<!DOCTYPE html>
<html>
<body>
<p>This is some text.</p>
<center>this text is line number one.
<br>this is line 2
<br>this is line number three</center>
<p>This is some text.</p>
</body>
</html>
此代碼爲您提供了這樣的輸出:
This is some text.
this text is line number one.
this is line 2
this is line number three
This is some text.
我想是居中左對齊文本,但保留原來的格式。即:第一行長,第二行短並居中在第一行下,並且第一行的第一個字母一路向左。對不起,如果這沒有意義。我不知道如何解釋它。
請不要使用'