Streaming live at 10am (PST)

Auto vs. relative

I have a menu bar, that i want to stay in one place all throughout the website.

Should it be positioned auto or relative?

I think you meant to say Navbar, you should use the position fixed to do this for it to ALWAYS stay in the same place no matter if you scroll ir not. :wink:

I would not like for it to be position:fixed, but rather it goes away when people scroll, like everything else.
There are minute differences between auto/relative, and i wonder if these differences apply to the menu bar. Here is the definition:

Auto elements are not affected by the top, bottom, left, and right properties. Keeps the original movement options, according to the normal flow of the page. All elements are static by default.
Relative Positioning: Setting the top, right, bottom, and left properties of a relatively-positioned element will cause it to be adjusted away from its normal position. Other content will not be adjusted to fit into any gap left by the element.

Auto is fine for now. If there’s a benefit down the road to specifying relative, you can quickly change it if your navbar is a symbol.

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.