2015-05-06 02:19:05 +03:00
|
|
|
<section>
|
|
|
|
|
|
|
|
<h1 id="disabled-results">Disabled results</h1>
|
|
|
|
|
|
|
|
<p>
|
2015-08-09 21:19:39 +03:00
|
|
|
Select2 will correctly handle disabled results, both with data coming
|
2015-05-06 02:19:05 +03:00
|
|
|
from a standard select (when the <code>disabled</code> attribute is set)
|
|
|
|
and from remote sources, where the object has
|
|
|
|
<code>disabled: true</code> set.
|
|
|
|
</p>
|
|
|
|
|
|
|
|
<div class="s2-example">
|
|
|
|
<p>
|
|
|
|
<select class="js-example-disabled-results form-control">
|
|
|
|
<option value="one">First</option>
|
|
|
|
<option value="two" disabled="disabled">Second (disabled)</option>
|
|
|
|
<option value="three">Third</option>
|
|
|
|
</select>
|
|
|
|
</p>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<pre data-fill-from=".js-code-disabled-results"></pre>
|
|
|
|
|
|
|
|
<script type="text/x-example-code" class="js-code-disabled-results">
|
|
|
|
<select class="js-example-disabled-results">
|
|
|
|
<option value="one">First</option>
|
|
|
|
<option value="two" disabled="disabled">Second (disabled)</option>
|
|
|
|
<option value="three">Third</option>
|
|
|
|
</select>
|
|
|
|
</script>
|
|
|
|
|
|
|
|
</section>
|