Materialize: How Can i enabled and disabled a multiselect way JS/jQuery

Created on 23 Jul 2016  路  2Comments  路  Source: Dogfalo/materialize

I have a multiselect disabled <select multiple disabled>

image

i want to enable the select element (when the checkbox is checked) i try:
$("select").prop('disabled', false) but doesnt work.

thanks for your help.

Most helpful comment

I suppose that after .prop('disabled', false) you need to run $('select').material_select();

Generally, after any operation on materializedselect tag you need to call $('select').material_select(); to sync dropdown with underline hidden select.

All 2 comments

I suppose that after .prop('disabled', false) you need to run $('select').material_select();

Generally, after any operation on materializedselect tag you need to call $('select').material_select(); to sync dropdown with underline hidden select.

@kmmbvnr Thanks You, its works, re-run $('select').material_select();

Was this page helpful?
0 / 5 - 0 ratings

Related issues

ReiiYuki picture ReiiYuki  路  3Comments

ruslandzhumaev picture ruslandzhumaev  路  3Comments

heshamelmasry77 picture heshamelmasry77  路  3Comments

SoproniOli713 picture SoproniOli713  路  3Comments

djensen47 picture djensen47  路  3Comments