我正在使用带标题标签的html。
例如:
<html>
<head>
<title> Title Name </title>
</head>
</html>
在这里我想要使用html代码在“标题名称”之后的长空格。
我试图使用
,但它太长了,无法放置代码。标题之后的任何其他空间替代。
答案 0 :(得分:1)
如果您的问题是您只是想避免编写长和大部分
代码。如果你使用PHP,我建议你这样做:
<title>Start <?php str_repeat(" ", 30); ?> End</title>
否则,我发现像你一样使用
很多没问题。
答案 1 :(得分:1)
我不明白为什么长度会成为问题,但您可以使用实际的NO-BREAK SPACE U + 00A0字符而不是实体引用
,例如
<title>Title Name </title>
答案 2 :(得分:1)
关于FeRtoll的答案,既然你不想使用PHP,你可以使用JavaScript库将一些PHP函数移植到JS。
答案 3 :(得分:1)
, 
, 
和 
呢?