Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8590137
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T23:13:32+00:00 2026-06-11T23:13:32+00:00

On the image hover , I want to display a different small image on

  • 0

On the image hover, I want to display a different small image on it with a background and opacity so that the original image is still visible. I want to use the transition to slow the hover effect.
So here’s what I’m trying and not working:

HTML:

<img src="http://i50.tinypic.com/2poy3kl.jpg" class="test" />

CSS:

.test {
   background: red url("http://i50.tinypic.com/10mue4k.png");
   transition: background .25s ease-in-out;
   -moz-transition: background .25s ease-in-out;
   -webkit-transition: background .25s ease-in-out;
}

.test:hover {
    opacity: 0.5;   
}

JS Fiddle:
http://jsfiddle.net/AXQW4/2/

Can someone please help me with this?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-11T23:13:33+00:00Added an answer on June 11, 2026 at 11:13 pm

    You’ll need an additional wrapper for this. Exactly the size of the image, and give that the background. Then, when you hover over the image, you hide it and the underlying background is revealed.

    Live example

    HTML

    <div class="background">
        <img src="http://i50.tinypic.com/2poy3kl.jpg">
    </div>
    

    CSS

    * {
        padding: 0;
        margin: 0;
        -webkit-box-sizing: border-box;
    }
    .background {
        background: url("http://i50.tinypic.com/10mue4k.png");
        display: inline-block;
        font-size: 0;
    }
    .background img {
        -webkit-transition: all .5s;
    }
    .background img:hover {
        opacity: 0.5;
    }
    

    No need to know the exact dimensions of the image.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I've got a background image that changes to another image when :hover. I used
I want a button that Displays an image with NO border, NO background, NO
I want to change button's background image y position with hover function. Is there
I want to show a a DIV on image / link hover and i
I have a bunch of images lined up that I want to on hover
I am using qTip 2 to display a larger image on hover and it
i make navigation function that changes navigation default image to hover image. default image
so I have a simple problem. I have a hover background image change effect,
I want to hover the image in static FBML page. But even the following
I want to use the hover feature of cluetip jquery plugin . I am

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.