简体   繁体   中英

CSS Attribute selector when an attribute is not set (or how do I only select non disabled input[type=“text”])

I'm using JQuery to try to select the textboxs on a form that are not disabled. My efforts have been fruitless since I don't know how to select all the input[type="text"] but also are not set to disabled.

result so far:

$('#signature INPUT[type="text"]');

Try this:

$('#signature input:text[disabled!=disabled]');

In english, find all input elements inside #signature which are of type text and which do not have their disabled attribute set to disabled .

尝试这个:

$('#signature INPUT[type="text"]:not(:disabled)');

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

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