动态调整选择框的宽度

时间:2013-09-16 15:12:24

标签: html

可以根据所选的选项动态更改选择框的宽度,而不是使用px固定选择下拉列表的宽度。例如,取决于选择框将调整大小的日期。

  <select name="day"  class="activity-filter"  >
        <option value="/customer/8708?day=Any+Day">Any Day</option>
        <option value="/customer/8708?day=Mon">Monday</option>
        <option value="/customer/8708?day=Tue">Tuesday</option>
        <option value="/customer/8708?day=Wed">Wednesday</option>
        <option value="/customer/8708?day=Thu">Thursday</option>
        <option value="/customer/8708?day=Fri">Friday</option>
        <option value="/customer/8708?day=Sat">Saturday</option>
        <option value="/customer/8708?day=Sun">Sunday</option>
      </select>

0 个答案:

没有答案