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 6913853
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T09:16:14+00:00 2026-05-27T09:16:14+00:00

It may be that I am missing something obvious, but I can’t work out

  • 0

It may be that I am missing something obvious, but I can’t work out how to reveal a hidden image/DIV slowly, so that it is shown from top to bottom.

If you look at this jsfiddle you will see the image that I am trying to reveal using ‘show’ in jQuery:

http://jsfiddle.net/nickharambee/Lj7z9/13/

The trouble with ‘show’ is that it grows the image from top left.

What I am looking for is an effect that hopefully is clear from these images:

enter image description hereenter image description hereenter image description hereenter image description hereenter image description here

i.e. the red ‘home’ image/DIV is gradually revealed from top to bottom so that it overlays the brown ‘home’ image.

Is it possible to achieve an effect like this with jQuery and if so what would be the best method? I am wanting to use this transition on all of the images in my nav bar.

Thanks,

Nick

ADDED CODE

HTML:

<li id="test2"><img src="images/home3.png"></li>

CSS:

li {
    background: url('images/sprite.png') no-repeat;
    background-position: 0px 0px;
    height: 40px;
}

SCRIPT:

$("li#test2").hover(
      function () {
        $(this).animate({
          'background-position-y': '-40'
        }, 500);
      },
      function () {
        $(this).animate({
          'background-position-y': '0'
        }, 500);
      }
    );
  • 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-05-27T09:16:15+00:00Added an answer on May 27, 2026 at 9:16 am

    Put the hover image in a div that has this style class:

    .blind {
        height: 0px;
        overflow: hidden;
    }
    

    That makes the image invisible because its container (the div) is zero-height and its overflow (the whole image) is hidden.

    Then animate div.blind like so:

    $('.blind').animate({height: "40px"});
    

    Now the image’s container is big enough for the whole hover image. The hover image is gradually revealed, from top to bottom.

    I have this working at: http://jsfiddle.net/cHt8V/1/

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

Sidebar

Related Questions

I may just be missing something obvious here, so I apologize if this is
I may be missing something obvious about this in the documentation for addKeyListener ,
That may be really simple but I'm unable to find a good answer. How
You may thick that it is a silly question but I am confused! I
I know that may sound silly, but I'm trying to submit a form on
I am sure this should be easy, perhaps I am missing something obvious. I
(This is a probably a very beginner question and I may be missing something
this may seem obvious, but I've been researching this all night to no avail.
You may argue that this question has a legal flavor to it, and that
I have a data stream that may contain \r, \n, \r\n, \n\r or any

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.