Ehsaan Israr Ehsaan Israr - 1 year ago 151
jQuery Question

how to make select drop down list read only and unchangeable

Here is a link of js fiddle


i make select dropdown read only but when i click on it it shows me the drop down option which should not show and it is changeable

Can you suggest a solution and update that in jsfiddle

Answer Source

use disabled attribute

 <div class="col-sm-8"><select class="form-control" id="id_messageKindId" name="messageKindId" disabled="disabled" required="required" readonly="">
<option value="1">Appointment Reminder</option>
<option value="2">Eyeware or Contact Arrival</option>
<option value="3">Appt Delay / Move Up</option>
<option value="4">Appt Cancellation</option>
<option value="5">Recall</option>
<option value="7">After Appointment</option>
<option value="10" selected="selected">Pre Appointment</option>
<option value="11">Lab Results</option>
<option value="12">Collection Message</option>
<option value="13">Custom Message</option>

fiddle at

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download