使用Div显示表格式数据
问题描述:
我要显示以下数据:
Title Subject Summary Date
所以我的 HTML
看起来像:
<div class="title"></div>
<div class="subject"></div>
<div class="summary"></div>
<div class="date"></div>
问题是,所有文本不会出现在一行。我尝试添加 display =block
,但这似乎不起作用。
The problem is, all the text doesn't appear on a single line. I tried adding display="block"
but that doesn't seem to work.
这里?
重要提示:在此示例中,我不想使用表
元素但贴上 div
标签。
Important: In this instance I dont want to use a table
element but stick with div
tags.
答
想要显示表,对吗?因此,请先使用< table>
It looks like you're wanting to display a table, right? So go ahead and use the <table> tag.