Reputation: 329
Is there a good CSS3 way of styling the img tag if it has a certain width without having to include a class to the image. (Perhaps using something like the
@media
queries)
Upvotes: 0
Views: 1641
Reputation: 1781
If the width
is specified in the HTML like :
<img src=".." width=250>
Then you can use this CSS :
img[width='250'] {
/* style */
}
Upvotes: 4