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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 2, 20262026-06-02T18:07:34+00:00 2026-06-02T18:07:34+00:00

I have a responsive site where I’m using a javascript to create a sticky

  • 0

I have a responsive site where I’m using a javascript to create a sticky sidebar.

I’m also using media queries to change from a multi-column layout to a single-column layout when the browser size is less than 768px.

I need to figure out how to disable the sticky menu script in the single-column layout. Essentially, I need something like a media query for the script statement.

This is the code I’m using to enable the script:

<script>
jQuery('#info').containedStickyScroll({
        duration: 0,
        unstick: false
    });
</script>

Is there something I can add to it to only have it trigger if the window is 768px wide or wider?

EDIT: I’m looking for a solution that will work if the user resizes the window on the fly.

  • 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-02T18:07:36+00:00Added an answer on June 2, 2026 at 6:07 pm

    Try this.

    $(function(){
         $(window).resize(function(){
             if($(this).width() >= 768){
                 jQuery('#info').containedStickyScroll({
                     duration: 0,
                     unstick: false
                 });
             }
          })
          .resize();//trigger resize on page load
    });
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a responsive site that I'm developing where I'm using a image slider
I'm writing a simple web page using responsive web design, so CSS3 media queries
I'm trying to create a responsive gui, which basically means that I have an
I have a JSON response that is formatted from my C# WebMethod using the
Have finally got a responsive site working (of a fashion). What I want to
I'm building a responsive site, and on one particular page, I'm trying to have
I am trying to use colorbox with an upcoming responsive site. I don't have
I have been looking at making the switch from SQL TableAdapters to Linq using
I have a stream that is reading the response from a site. I am
I have a responsive wordpress theme and the right site of the site i

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.