Consider the following scenario:
<input type='text' />
<br />
<iframe>
<input type='text'>
</iframe>
With the style defined as:
input[type='text'] {
border: 1px solid black;
}
If you want the styles to only apply to elements outside of the iframe, how can you achieve this? The idea of using the CSS :not
selector comes to mind, but you may be unsure of how to implement it. You might be aiming for something like:
input[type='text'], input:not(iframe) {
border: 1px solid black
}
Or in other words, you want to "Apply styles to all input elements of type text EXCEPT those within an iframe".