当前位置: 动力学知识库 > 问答 > 编程问答 >

html - Align Image and text in a table row

问题描述:

I have a table likes this:

<table>

<tbody>

<tr>

<td valign="middle;"><img src="icon.jpg" style="vertical-align: middle;" />title</td>

<td valign="middle;">detail</td>

</tr>

</tbody>

</table>

I want the image, title and detail to be aligned in a row, so I apply valign to the 3 elements. But it doesn't work well as image can only align with title but image+title cannot align with detail. Please help.

网友答案:

remove ; from the value of valign attribute

分享给朋友:
您可能感兴趣的文章:
随机阅读: