Is it possible to use an input value attribute as a CSS selector?

后端 未结 9 2290
[愿得一人]
[愿得一人] 2020-11-27 17:07

Is it possible to use a CSS selector to target an input that has a specific value?

Example: How can I target the input below based on the value=\"United States

9条回答
  •  [愿得一人]
    2020-11-27 17:18

    As mentioned before, you need more than a css selector because it doesn't access the stored value of the node, so javascript is definitely needed. Heres another possible solution:

    
    
    
    

提交回复
热议问题