Pregunta

How can I add specifity to something that reads:

input[type="text"] { color:red }

I want something like:

#my_id input[type="text"] { color:red }
¿Fue útil?

Solución

You mean like this?

input[type="text"]#my_id { color:red }

See the demo

Otros consejos

When you use an id and don't want to address a child node you can omit any other parts, a id must be unique so far you can use just:

#my_id { color:red }
Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top