Click to See Complete Forum and Search --> : RE:individual image borders (NOT ACTIVATED)


danam22315
08-07-2004, 12:25 PM
I am new to HTML, and have a question that has probably already been answered, but here goes.
I want to set up a "style sheet " for images. I'm creating a fan web page for a t.v. show, and I want to use a DIFFERENT border color for each character/actor. However, I DO NOT WANT TO ACTIVATE THE IMAGES.
Is there a way I can do this??

confused
danam22315

IncaWarrior
08-07-2004, 12:28 PM
What does "activate the image" mean?
put in the header:
<style>
#bob{border:solid 2px red}
#sue{border:solid 2px green}
#joe{border:solid 2px blue}
</style>

then for your images:
<img id="bob" src="bob.gif" alt="bob">
<img id="sue" src="sue.gif" alt="sue">
<img id="joe" src="joe.gif" alt="joe">

PhillMc
08-07-2004, 12:34 PM
I'm assuming that he means 'not-clickable' or 'non-anchored'.

ray326
08-07-2004, 09:54 PM
Also I think he'd want to use classes instead of ids because I *think* he wants this to happen on all images throughout the site, including multiples per page.

fredmv
08-08-2004, 12:17 AM
For Mozilla:img[src*="bob"] {
/* rules */
}And so on. Sucky IE can't even go near this kind of syntax though. :rolleyes:

Stephen Philbin
08-08-2004, 09:22 AM
Is that kind of syntax a recomendation?

fredmv
08-08-2004, 09:39 AM
Originally posted by Mr Herer
Is that kind of syntax a recomendation? Do you mean as in a preferred way or in the W3C reccomendation?

If so, probably both. A general recommendation because it's dynamic. You don't have to litter your markup with extra attributes or modify it in any way. Hence, the markup is completely untouched.

A W3C recommendation for sure as it's in the CSS3 spec (http://www.w3.org/TR/2001/CR-css3-selectors-20011113/#attribute-selectors).

P.S. Despite how useful this is, only Mozilla implements it as of now.

Stephen Philbin
08-08-2004, 09:59 AM
Well I did mean in the W3C sense yeah. What other kinds of browsers other than Moxilla and IE are there though (besides the obvious screen readers etc) ?

Currently, I onlt test with IE and NN and FF which are both Mozilla anyway. Can I grab myself Opera for free? Last time I tried getting it it was asking for cash that I simply do not have. Anywhere I can grab a batch of free browsers that'd be good for testing?

IncaWarrior
08-08-2004, 01:56 PM
I use opera (the newest one) with a little ad at the top. It's free like this.

danam22315
08-11-2004, 10:25 PM
Thanks for all the suggestions.
When I wrote NOT ACTIVATED I DID mean that I did not want to make the image clickable.
I will try these suggestions as soon as I can, but I REALLY want to say THANKS FOR ALL THE HELP.

YOU GUYS ROCK!