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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T04:06:42+00:00 2026-06-10T04:06:42+00:00

This is the page example I am working on : http://tommywebdesigner.com/Vision.html I want the

  • 0

This is the page example I am working on : http://tommywebdesigner.com/Vision.html

I want the part from the Title Vision General till the icon arrow down gets fixed on the top when I scroll down the page. Can you tell me the best method to achieve that?

Basically I have seen an example where the class becomes fixed when the page comes to the div. My case should be similar but without the menu fixed as in this example.

  • 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-10T04:06:44+00:00Added an answer on June 10, 2026 at 4:06 am

    From taking a look at the other examples I’ve located the javascript that takes care of that for you. They use jQuery. Here is the code, Sorry it’s long:

    /*
     *
     * Fold/unfold header
     *
    */
    var snapped = false;
    function fixHeader(){
        $('#headercontainer, body').addClass('fixed')
    }
    
    
    function headerUnfold(){
        $("header").animate({
            "height" : 157
        },300, "swing");
    
    
        //if header is fixed
        if($('body.fixed').length && !snapped){
            $('#content').animate({
                'margin-top' : 185
            },300, "swing");
        }
        if($('body.fixed').length && snapped){
            $('#submenucontainer').animate({
                'margin-top' : 90
            },300, "swing");
        }
    
    
        $("nav, #menu_aux").fadeIn('fast');
        $("#menuback").hide();
        $("header").bind('mouseleave' , function(){
            headerFold(true);
        })
        }
    
        function headerFold(animate){
        $("header").unbind('mouseleave');
        if(animate){
            time = 300;
        }else{
            time = 0;
        }
        $("header").animate({
            "height" : 65
        },time, "swing")
    
        //if header is fixed
        if($('body.fixed').length && !snapped){
            $('#content').animate({
                'margin-top' : 80
            },300, "swing");
        }
    
        if($('body.fixed').length && snapped){
            $('#submenucontainer').animate({
                'margin-top' : 0
            },300, "swing");
        }
    
    
        if(animate){
            $("nav, #menu_aux").fadeOut('fast');
        }else{
            $("nav, #menu_aux").hide();
        }
    
        $("#menuback").css({
            "left" : -10
        }).show().animate({
            "left" : 20
        },time)
        }
    
        $("#menuback").bind('mouseenter', function(){
        headerUnfold();
        })
    

    Just make the element that you want the effect for id submenucontainer. If you want a more direct link to the JS here it is.

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

Sidebar

Related Questions

Let's say this page www.example.com/mypage returns some html that I want to parse in
For Actionscript 2.0 Let's say this page www.example.com/mypage returns some html that I want
I want to subscribe to a facebook page for example with this url ,http://www.myurl.com
Trying to get this example working from http://www.munna.shatkotha.com/blog/post/2008/10/26/Light-box-effect-with-WPF.aspx However, I can't seem to get
I have a JSP page at an address like this: http://example.com/foo/bar/rawr/something.jsp When I output
Working example: http://jsfiddle.net/JVVcA/ HTML: <fieldset id=data-page> <legend>data-page</legend> <button rel=page1>Highlight page one</button> <button rel=page2>Highlight page
I'm scraping this page: http://kat.ph/search/example/?field=seeders&sorder=desc In this way: ... curl_setopt( $curl, CURLOPT_URL, $url );
Example form, https://stackoverflow.com/questions/ask and I save this page to desktop. Then I edit the
This project was coped almost exacatly from the example on the admob page but
Example of failure: http://progamonth.com/files/testfile.html Desired Behavior: Ideally, any headers with a colspan shouldn't affect

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.