并排显示dt标签,而不是一个在另一个之下 [英] displaying dt tag side by side instead of one below another

查看:201
本文介绍了并排显示dt标签,而不是一个在另一个之下的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想并排显示 dt 的HTML标签,而不是一个低于另一个
例如: -

I want to display dt of HTML tag side by side instead of one below another For example:--

<dl class='Desktop'>
  <dt class='first'>first</dt>
  <dt class='Second'>second</dt>
  <dt class='third'>third</dt>
</dl>

输出:第一个 second third

推荐答案

所有其他的答案,因为他们是好的,但我认为我是一个简单得多,并不需要IE黑客:

I like all the other answers as they are good, but I think mine is a lot simpler and doesn't require IE hacks:

dt {
    display: inline;
}

这篇关于并排显示dt标签,而不是一个在另一个之下的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆