border="0"

N

Nathan Sokalski

To apply it to all img tags, use:
img { border: none; }

If you use:
a img { border: none; }

Then it will be applied only to img tags that are descendents of a tags (not
necessarily immediate children, as long as they are descendents)

I would suggest the first one if you want this for all img tags, because it
is a more straightforward and direct selector. Also, it takes away the need
to worry about fixing stuff if you were to decide to change something.
Hopefully this helps.
-
Nathan Sokalski
(e-mail address removed)
http://www.nathansokalski.com/
 
G

Gregory A. Beamer

I just want to point out something about your CSS selector:

.img{border: 0px;}

Will create a CSS class named "img" that you would use by specifying
the class attribute in the html tag, such as:

<img class="img"/>

This is probably not what you wanted, and you definitely don't want to
give a CSS class the name "img". If you want to use a selector that
will apply the CSS properties to all img tags, do the following:

img{border: 0px;}

Notice that the difference is that there is no period before this, it
is simply the tag name. You may want to do a little reviewing of the
general syntax for CSS. Hopefully this helps.


That was the reason for the disclaimer in the post. LOL

I did not have time to check my work, so I took a risk and lost. ;-(

Thanks for correcting for the peeps out there.
 
A

AAaron123

Nathan said:
To apply it to all img tags, use:
img { border: none; }

If you use:
a img { border: none; }

Then it will be applied only to img tags that are descendents of a
tags (not necessarily immediate children, as long as they are
descendents)

I would suggest the first one if you want this for all img tags,
because it is a more straightforward and direct selector. Also, it
takes away the need to worry about fixing stuff if you were to decide
to change something. Hopefully this helps.
-
Nathan Sokalski
(e-mail address removed)
http://www.nathansokalski.com/

This is the example I had found earlier.
I B {font-size:16px;}

effective here

<i><b>example</b></i>

From your terminology I think the following is correct:

<i> is a branch

and <b> is a branch on the <i> branch (i.e., a twig on <i>).

Therefore, <i> is a descendent of <b>.



Is the above correct?

Thanks
 
N

Nathan Sokalski

Not quite. In your example:

<i><b>example</b></i>

<b> is a descendent of <i> because <b> is nested inside <i>.
 
A

AAaron123

That is actually what I was thinking.
Don't know why I wrote it backwards on the last line.
<b> is a child as well as a descendent of <i>

Thanks a lot
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,774
Messages
2,569,598
Members
45,160
Latest member
CollinStri
Top