Thumbnail background colour before rollover
-
Hi All,
I hope you can help. I am trying to create thumbnails that have a 70% background colour over the thumbnail image BEFORE rollover rather than after (which can be done easily in the customise section of Lay).
I have tried to write the css but it doesn't seem to work. Below is a link to a faked version (using two images rather than code):
http://www.martinedwardsarchitects.com/overview/Thanks in advance!
M
-
Dear @mike
try to add something like this to your CUSTOM CSS:
.thumbnail-wrap a img { opacity: 0.7 !important; } .thumbnail-wrap a img:hover { opacity: 1 !important; }
It is just a quick sketch. But it should do the job.
Best!
Marius
-
Thanks Marius!
It works for opacity but does not add the background colour. I want a #e2eded blue to present in the thumbnail before rollover. I've tried adding background colour to the css you gave me but it doesn't seem to work. Any ideas?
Thanks again,
M
-
Dear @mike
ah. I see.
This is not really possible.
You could use CSS with blending modes:
https://css-tricks.com/basics-css-blend-modes/But they don't get supported by all browsers.
Best is to use prepared images.
Marius
4/4
Need custom programming for your Lay Theme site?
I regularly add new features to Lay Theme for free, based on user feedback. But if you or your client need something more specific, I’m happy to offer custom paid programming tailored to your project.
Email info@laytheme.com with the subject "Custom paid programming for Lay Theme" and a short description of what you need — I’ll reply with a cost estimate.
Custom features I build often make it into future Lay Theme updates, so your idea might benefit the whole community.
Before you post:
- When using a WordPress Cache plugin, disable it or clear your cache.
- Update Lay Theme and all Lay Theme Addons
- Disable all Plugins
- Go to Lay Options → Custom CSS & HTML, click "Turn Off All Custom Code", click "Save Changes"
This often solves issues you might run into
When you post:
- Post a link to where the problem is
- Does the problem happen on Chrome, Firefox, Safari or iPhone or Android?
- If the problem is difficult to explain, post screenshots / link to a video to explain it