本文介绍了什么时候是使用< b>的最佳时间?和< i>代替< strong>和< em>(如果有)?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

从严格意义上讲,在当今的网站(2008年末以后)中,使用粗体< b> 和斜体< i> 标签的位置是否合适?比更广泛使用的< strong> < em> 标签有用吗?

Semantically speaking, is there an appropriate place in today's websites (late 2008+) where using the bold <b> and italic <i> tags are more useful than the more widely used <strong> and <em> tags?

推荐答案

从不.由于它们是表示性标记,因此已在XHTML 2.0中删除.CSS应该用于加粗/斜体显示内容.

Never. They are removed in XHTML 2.0 as they are presentational tags. CSS should be used to bold/italicise content.

编辑:如果您正在寻找一个纯粹的演示标签,那就是带有类和少量CSS的 SPAN 标签的用途.

edit: If you're looking for a purely presentational tag, that's what the SPAN tag with a class and a little CSS is for.

这篇关于什么时候是使用&lt; b&gt;的最佳时间?和&lt; i&gt;代替&lt; strong&gt;和&lt; em&gt;(如果有)?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

06-20 12:32