Replies

Jul 1, 2015 10 years ago
Ferrox
has 40 pets and counting
User Avatar
Reggie

I need some help on him: http://subeta.net/pets/Vasili I put an image of him under the story section and positioned it so it is on the right beside the text. Now I'd like the image itself to have full opacity but the remaining should stay with opacity at 0.5. Is this even possible, to make two elements within that div in different opacity?

Thanks a lot for any help in advance^^

Jul 4, 2015 10 years ago
Adventure Captain
sonata
User Avatar

An object inherits its opacity from the parent div, so since the box is at a lowered opacity, so is the image.

Are you only using lowered opacity to make the box slightly see-through? Because it that is the case you can achieve that with rgba colors. That way the background color can be semitransparent but the content will still show at full opacity.

Art by
[tot=sonata]

Jul 4, 2015 10 years ago
Ferrox
has 40 pets and counting
User Avatar
Reggie

Thank you very much for your help. I tried it the way you described but when I try to do so either the whole opacity-thing is gone or nothing does happen at all Dx

Jul 4, 2015 10 years ago
Adventure Captain
sonata
User Avatar

It's probably not a good idea anyway. I just remembered how your profiles are coded and transparent backgrounds would just mess with that. ^^;

Anyway, as I said, since the image is inside a div with lowered opacity it can't display at full opacity.

Art by
[tot=sonata]

Jul 4, 2015 10 years ago
Ferrox
has 40 pets and counting
User Avatar
Reggie

Would it be possible to put a transparent image beside the story and than put the image I actually want there over the transparent image (using z-index or something) but still inside a div so it is only visible when clicking on the "story" button? (sorry for being so bad at explaining Dx)

Jul 5, 2015 10 years ago
egg
is a bad egg
User Avatar

No, that wouldn't work, since the image is actually /in/ the story div, and I don't think you can have two divs tied to one anchor link.

What I would do, instead of using an opacity at all, is add the blue box to the main image background, so that it's always there, rather than coding it as a blue background. Then the images inside the div will be normal, and if you want to mess with text, you can change the opacity of that with rgba like mentioned. :3

(did that make sense at all? I really suck at explaining anything)

Jul 5, 2015 10 years ago
Ferrox
has 40 pets and counting
User Avatar
Reggie

Oh my you are right feels so stupid for not thinking about that in the first place Thank you so much, I am totally going to do it that way^.^

Please log in to reply to this topic.