Fixed (static) Header?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • zapiy
    Member
    • Mar 2008
    • 58

    [Forum] Fixed (static) Header?

    Hi we are looking at fixing the header so it remains in position when scolling i changed the position in the css from relative to fixed and it goes out of sync totally.

    Any help please?
  • Lynne
    Former vBulletin Support
    • Oct 2004
    • 26255

    #2
    Can we get a link to see what is going on?

    Please don't PM or VM me for support - I only help out in the threads.
    vBulletin Manual & vBulletin 4.0 Code Documentation (API)
    Want help modifying your vbulletin forum? Head on over to vbulletin.org
    If I post CSS and you don't know where it goes, throw it into the additional.css template.

    W3Schools <- awesome site for html/css help

    Comment

    • zapiy
      Member
      • Mar 2008
      • 58

      #3
      Sure, http://www.forumfanatics.com/vbtest/?styleid=3

      The grey header area accross the width of the page at the very top... We want that to remain in position when scrolling..

      Cheers

      Comment

      • Lynne
        Former vBulletin Support
        • Oct 2004
        • 26255

        #4
        You need to set the position as "fixed" and then set top and left (probably both 0) and a width (100%)
        HTML Code:
        #header {height:80px;left:0;position:fixed;top:0;width:100%;z-index:1;}

        Please don't PM or VM me for support - I only help out in the threads.
        vBulletin Manual & vBulletin 4.0 Code Documentation (API)
        Want help modifying your vbulletin forum? Head on over to vbulletin.org
        If I post CSS and you don't know where it goes, throw it into the additional.css template.

        W3Schools <- awesome site for html/css help

        Comment

        • zapiy
          Member
          • Mar 2008
          • 58

          #5
          Which file should i edit?

          When i search for #header it finds 2 templates vbulletin-chrome.css and stylegenerator.css.

          Thanks

          Comment

          • zapiy
            Member
            • Mar 2008
            • 58

            #6
            We have lost all the links on it now though to forum whats new and so on?

            Comment

            • Lynne
              Former vBulletin Support
              • Oct 2004
              • 26255

              #7
              Originally posted by zapiy
              Which file should i edit?

              When i search for #header it finds 2 templates vbulletin-chrome.css and stylegenerator.css.

              Thanks
              As my signature says, if I don't state where to put the CSS, then put it into the additional.css file.

              Please don't PM or VM me for support - I only help out in the threads.
              vBulletin Manual & vBulletin 4.0 Code Documentation (API)
              Want help modifying your vbulletin forum? Head on over to vbulletin.org
              If I post CSS and you don't know where it goes, throw it into the additional.css template.

              W3Schools <- awesome site for html/css help

              Comment

              • zapiy
                Member
                • Mar 2008
                • 58

                #8
                Thanks but the buttons still disappear?

                Comment

                • Lynne
                  Former vBulletin Support
                  • Oct 2004
                  • 26255

                  #9
                  You mean the navbar stuff? So include that in the CSS also. Right now, you've totally hidden them with this:

                  HTML Code:
                  margin: -40px 70px 200px;

                  Please don't PM or VM me for support - I only help out in the threads.
                  vBulletin Manual & vBulletin 4.0 Code Documentation (API)
                  Want help modifying your vbulletin forum? Head on over to vbulletin.org
                  If I post CSS and you don't know where it goes, throw it into the additional.css template.

                  W3Schools <- awesome site for html/css help

                  Comment

                  • zapiy
                    Member
                    • Mar 2008
                    • 58

                    #10
                    just by removing that code?

                    Comment

                    • Lynne
                      Former vBulletin Support
                      • Oct 2004
                      • 26255

                      #11
                      Well, you need to change that in order to see the navbar in the first place. If you want it to stay static, then you need to apply the same sort of CSS I posted to .navbar area also (position:fixed; top: 40px or so, left:0 etc.). And then you'll have to position .above_body also.

                      This really is something you may want to ask for help with over on vbulletin.org, the modification site.

                      Please don't PM or VM me for support - I only help out in the threads.
                      vBulletin Manual & vBulletin 4.0 Code Documentation (API)
                      Want help modifying your vbulletin forum? Head on over to vbulletin.org
                      If I post CSS and you don't know where it goes, throw it into the additional.css template.

                      W3Schools <- awesome site for html/css help

                      Comment

                      widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
                      Working...
                      😀
                      😂
                      🥰
                      😘
                      🤢
                      😎
                      😞
                      😡
                      👍
                      👎