并排显示一张桌子,一个iframe和一张桌子
问题描述:
我想要并排显示一张桌子,一张iframe和一张桌子。有没有休息或之间的任何事情。我希望所有三个中心最好。并排显示一张桌子,一个iframe和一张桌子
这没有任何意义。在我的屏幕显示足够大的情况下,在同一“线路”上可以显示足够的空间。
请帮忙。如下图所示
代码:
<center>
<table border="0">
<tr id="hidethis" style="display:none;">
<td><iframe src="menu.html"height=450 width=400 frameborder=0 name = "list" style =""></></iframe></td>
</tr>
<tr id="hidethisalso" style="display:none;">
<td>Enter code for song to play</td>
</tr>
</table>
<iframe height=450 width=450 frameborder=0 name = "cake" style =""></></iframe>
<table border="0">
<tr id="hidethistoo" style="display:none;">
<td><iframe src="menu.html"height=450 width=400 frameborder=0 name = "list" style =""></></iframe></td>
</tr>
<tr id="hidethisaswell" style="display:none;">
<td>Enter code for song to delete</td>
</tr>
</table>
</center>
答
裹在<div style="inline-block">...</div>
表这将使表的行为对你
<center>
<!-- wrap the table in an inline-block to make it behave -->
<div style="display:inline-block">
<table border="0">
<tr id="hidethis" style="display:;">
<td><iframe src="menu.html"height=450 width=400 frameborder=0 name = "list" style =""></></iframe></td>
</tr>
<tr id="hidethisalso" style="display:none;">
<td>Enter code for song to play</td>
</tr>
</table>
</div>
<iframe height=450 width=450 frameborder=0 name = "cake" style =""></></iframe>
<!-- wrap the table in an inline-block to make it behave -->
<div style="display:inline-block">
<table border="0">
<tr id="hidethistoo" style="display:;">
<td><iframe src="menu.html"height=450 width=400 frameborder=0 name = "list" style =""></></iframe></td>
</tr>
<tr id="hidethisaswell" style="display:none;">
<td>Enter code for song to delete</td>
</tr>
</table>
</div>
</center>
+0
Perfecto。干杯Jaromanda X. – miasweb
你可以尝试将每个表格包装在它自己的div中,它具有样式'display:inline-block' –
你知道一种只使用Javascript和HTML的方式 - 不使用CSS。无论如何,感谢您的帮助。谢谢你的时间。 – miasweb
你有内联的CSS,为什么解决方案不能做到这一点? –