Exclude specific images from CSS
-
Hi!
Recently I have put the next CSS code for all images of my blog:
img {
border: inset gold 6px;
}It has worked, but now I need another one that makes some specific images without any border.
For example, in this page: http://comojuega.com/2013/12/19/boca-juniors-2/
… I would like that argentinean flags (http://www.eurobasket.com/images/Iconsflags/Argentina.gif) dont show any kind of border, or at least, one smaller.
Thanks!
The blog I need help with is: (visible only to logged in users)
-
Since the flag images are not hosted here, you cannot specifically target them in the custom CSS. What you would want to do is to modify the HTML code for that image and use an inline style declaration for border: none as I have done below. You will have to edit each instance of that flag insertion, or replace the existing code you have for the flag by copying and pasting the entire code below.
<img style="border: none;" src="http://www.eurobasket.com/images/Iconsflags/Argentina.gif" alt="http://www.eurobasket.com/images/Iconsflags/Argentina.gif"> -
If those images are all inside table cells, as on the example you linked to, you can easily exclude all of them this way:
table img { border: 0 none; }
- The topic ‘Exclude specific images from CSS’ is closed to new replies.