Bootstrap – Position


Bootstrap – Position



”;


This chapter discusses about configuration of position of an element.

Bootstrap provides a set of helper classes to set the position of an element on a page. Some of the classes provided by Bootstrap are as follows:.

  • .fixed-top

  • .fixed-bottom

  • .sticky-top

  • .sticky-bottom


Let us see examples for each set of classes.


Fixed top

The class .fixed-top sets the position of an element at the top of the viewport, from edge to edge.

This is useful for creating navigation bars or headers that remain visible at the top of the screen even as the user scrolls down.