简体   繁体   English

绑定Selectric jQuery Dropdown排除选定的选项

[英]Bind Selectric jQuery Dropdown excluding option selected

I am using selectric jQuery dropdown in my webdesign: 我在网页设计中使用selectric jQuery下拉列表:

<select id="RemoveReason">
    <option value="0">Reason for Disconnect</option>
    <option>Coverage</option>
    <option>Price</option>
    <option>Customer experience</option>
    <option>Serviceability</option>
    <option>Promotion</option>
    <option>Limited Device range</option>
</select>

With this I am getting the value at 0 position again in the select dropdown upon default select. 有了这个,我在默认选择的选择下拉列表中再次获得了位于0位置的值。 You can find an image here 你可以在这里找到图片

Can anyone help me to solve this problem? 谁能帮我解决这个问题? Thanks in advance. 提前致谢。

Add selected and disabled , I believe this is what you expected. 添加selecteddisabled ,我相信这是您所期望的。

 <select id="RemoveReason">
  <option value="0" selected disabled>Reason for Disconnect</option>
  <option>Coverage</option>
  <option>Price</option>
  <option>Customer experience</option>
  <option>Serviceability</option>
  <option>Promotion</option>
  <option>Limited Device range</option></select>

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM