对于简短的外语单词组,我应该使用哪个元素?
Which element should I use for short group of foreign langague words?
我想知道我应该在句子或段落中使用哪个 html 元素(比如 <p>
块)对于借来的单词或外语中的单词,指的是有效的语义。这里有几个例子:
英语
Tonight, I have a rendez-vous with a cute girl. (use of a French word)
He was not speaking loudly, but not more silently, indeed mezzo voce (use of an Italian word)
法语
Java n'est pas popriétaire, a contrario de .Net
在法语中,至少,这种外语的使用需要斜体格式。
所以我想结合语义和表示。 Wikipedia article on Semantic HTML 给我一个提示,但到目前为止我还不确定。此外,我可能无法控制 CSS,例如在文档 (wiki) 或描述文件 (pom) 中
哪个元素最适合我的要求:
<i>
(肯定不是 :))
<em>
(也许不是 :))
<cite>
<span lang="latin">
<span class="borrowed">
- 这些的组合
- 另一个标签
一个 span 和一个或多个 类 通常是可行的方法。
<span class="foreign-lang">bonjour</span>
与 css:
span.foreign-lang{
font-style:italic;
}
W3C 说
The i
element represents a span of text in an alternate voice or mood, or otherwise offset from the normal prose in a manner indicating a different quality of text, such as a taxonomic designation, a technical term, an idiomatic phrase from another language, transliteration, a thought, or a ship name in Western texts.
我的重点
他们的榜样
<p>There is a certain <i lang="fr">je ne sais quoi</i> in the air.</p>
我想知道我应该在句子或段落中使用哪个 html 元素(比如 <p>
块)对于借来的单词或外语中的单词,指的是有效的语义。这里有几个例子:
英语
Tonight, I have a rendez-vous with a cute girl. (use of a French word)
He was not speaking loudly, but not more silently, indeed mezzo voce (use of an Italian word)
法语
Java n'est pas popriétaire, a contrario de .Net
在法语中,至少,这种外语的使用需要斜体格式。
所以我想结合语义和表示。 Wikipedia article on Semantic HTML 给我一个提示,但到目前为止我还不确定。此外,我可能无法控制 CSS,例如在文档 (wiki) 或描述文件 (pom) 中 哪个元素最适合我的要求:
<i>
(肯定不是 :))<em>
(也许不是 :))<cite>
<span lang="latin">
<span class="borrowed">
- 这些的组合
- 另一个标签
一个 span 和一个或多个 类 通常是可行的方法。
<span class="foreign-lang">bonjour</span>
与 css:
span.foreign-lang{
font-style:italic;
}
W3C 说
The
i
element represents a span of text in an alternate voice or mood, or otherwise offset from the normal prose in a manner indicating a different quality of text, such as a taxonomic designation, a technical term, an idiomatic phrase from another language, transliteration, a thought, or a ship name in Western texts.
我的重点
他们的榜样
<p>There is a certain <i lang="fr">je ne sais quoi</i> in the air.</p>