Using jQuery, I am trying to disable all non-selected items in addition to one of several select elements I am I was trying to exclude a selection element based on my name attribute: name = "tloStatus" .
$ (document) .ready (function () {if ($ ("select [name! = TloStatus]")) {$ ('option: not (: selected)') ('Disabled', true);}}); How do I apply only:
$ ('option: no (: selected)'). Ether ('disabled' is true); On each selection element but name = "tloStatus" ?
The reason for this was not working, because you all unselected < Regardless of code> option elements select element name without regard to parent.
You can simplify it in the following so that only the unselected option element lineage
$ ("select [name! = TloStatus] option: no (: selected)"). ;
No comments:
Post a Comment