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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T11:39:26+00:00 2026-05-31T11:39:26+00:00

was working on a anchor point that triggers a divs visibility. There’s no problems

  • 0

was working on a anchor point that triggers a divs visibility. There’s no problems if I run it with Jquery 1.3.2 library but when I try with 1.7.1 it’s not recognized. any ideas?

$(function() {
var a = function() {
var windowtop = $(window).scrollTop();
var d = $("#anchor").offset({scroll:false}).top;
var c= $("#flyout");
if (windowtop > d) {
  c.css({visibility:"visible"});
} else {
  if (windowtop <= d) {
    c.css({visibility:"hidden"});
  }
}
};
$(window).scroll(a);a()
});
}); 
  • 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-31T11:39:27+00:00Added an answer on May 31, 2026 at 11:39 am

    d seems to always return undefined.

    I suspect your code breaks because of the {scroll:false} object your are passing as an argument to offset(). Removing it might solve your problem.

    Check the jQuery().offset() API;

    jQuery(elem).offset()returns an object containing the element’s top and left coordinates. Can be used as jQuery(elem).offset().top;.

    jQuery(elem).offset({top:20, left:20}); sets the new top and left coordinates for the element.

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

Sidebar

Related Questions

I'm working with jquery. I have an anchor tag that is generated dynamically in
Throughout a jQuery mobile site I am working on I have anchor tags that
I've got a working a.click() function in jquery... But if I click an anchor,
I'm working with jQuery's .data() method to store some extra data on an anchor
I have a URL with an anchor that is working as it should: site.com/item/id#comment-233
I’m working with HTML/Jquery code that our designer passed over to me so that
I'm working with JQuery and jsTree, and I've run into some confusion about how
Working with dates in ruby and rails on windows, I'm having problems with pre-epoch
Working with a SqlCommand in C# I've created a query that contains a IN
Working on a project that parses a log of events, and then updates a

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.