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

  • SEARCH
  • Home
  • 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 7421491
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 29, 20262026-05-29T08:25:05+00:00 2026-05-29T08:25:05+00:00

I am currently working on a one-page layout for a website. Each section of

  • 0

I am currently working on a one-page layout for a website. Each section of the page has a corresponding ‘topic’ logo which I would like to have jQuery fade it in when the user reaches the position. When moving further a certain amount of pixels (like 100px up or down) the image should fade out again. Is there an easy way to do this? The height of each div isn’t fixed (CMS behind it), so I couldn’t just go with a fixed px amount from the top or something. Of course, if you move further down/up to any of the other divs the images should fade in as in the first place.

Here’s my example code

<div role="main">
    <div id="first"><img … />content…</div>
    <div id="second"><img … />content…</div>
    <div id="third"><img … />content…</div>
</div>
  • 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-29T08:25:06+00:00Added an answer on May 29, 2026 at 8:25 am

    If I understood you correctly, here’s a quick demo of what you are looking for:

    • http://jsfiddle.net/G979Q/

    No images there, just colored divs, but if that’s what you want, you should be able to extend rather easily. Depending on other restrictions of how elements are placed by CMS, you might run into problems, but still the general idea should be applicable.

    Edit: just to make sure the comments are captured in the answer, for scrolling-based instead of mouse-based fades, here’s a quick demo:

    • http://jsfiddle.net/CPrcP/3/

    Credits:

    • http://css-tricks.com/snippets/jquery/calculate-distance-between-mouse-and-element/
    • jQuery fadeOut without display none?
    • http://api.jquery.com/mouseleave/

    Hope this helps.

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

Sidebar

Related Questions

I am currently working on a page that has a date picker for one
I'm currently working on a project with a one page design that'll slide up
I'm currently working on a page which makes use of the MS Ajax UpdatePanel.
I am currently working on building a baseball website. On one side of the
I'm currently working on a location page on a website and am having trouble
I'm working on a one page layout site, where I use jQuery Cycle to
I'm currently working on a page within one of my company's internet sites that
I am currently working with a client to redevelop their website. One of the
I am currently working with 2 sql 2000 servers one I can query but
I am currently working on a project where one of our goals is to

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.