2013-05-01 28 views
0

的宽度,我有一个表格单元格在一个表如下:如何使一个浮动范围,并选择元素填写表格单元格

<td> 
<span class="subtitle no-select" id="billing-status-span" style="float:left"> Status </span> 
<select id="bill-status" style="float:left"> 
    <option>One of many options with lots of text and therefore width</option> 
</select> 
</td> 

请告知

例如。想象一下td是100px宽(实际上td宽度是动态的,因为它是基于百分比的)。由于选择宽度大于100px,我该如何处理?我希望选择宽度缩小...但注意选项宽度迫使选择大于100px

+0

你是说“我如何使浮动跨度填充表格单元的宽度”? – hjpotter92 2013-05-01 11:00:09

+0

编号想象一下td是100px宽(实际上td宽度是动态的,因为它是基于百分比的)。由于选择宽度大于100px,我该如何处理?我想选择宽度缩小...但注意选项宽度迫使选择大于100px – 2013-05-01 11:16:49

回答

-1

我认为不需要标签只是为了状态。你可以只是 就像

<td>Status<select id="bill-status"> <option>One of many options with lots of text and therefore width</option></select></td> 
+0

真的吗?你尝试过吗? – Dementic 2013-06-18 14:47:35

相关问题