Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Save more on your purchases! discount-offer-chevron-icon
Savings automatically calculated. No voucher code required.
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Learning Bootstrap

You're reading from   Learning Bootstrap Unearth the potential of Bootstrap to create responsive web pages using modern techniques

Arrow left icon
Product type Paperback
Published in Dec 2014
Publisher Packt
ISBN-13 9781782161844
Length 204 pages
Edition 1st Edition
Languages
Arrow right icon
Toc

Using the Bootstrap Grid classes

You can create a page layout through a series of rows and columns that house your content. To set the maximum width of the page content according to the screen width, you have to use the .container class.

Note

Containers help define the space to be used by the Grid system.

The container width is set as follows:

  • Phone screens (less than 768 px resolution): The width of the container is the same width as the width of the screen
  • Tablet screens (between 768 px and 992 px resolution): The maximum width of the container is 750 px
  • Small desktop screens (between 992 px and 1200 px resolution): The maximum width of the container is 970 px
  • Large desktop screens (more than 1200 px resolution): The maximum width of the container is 1170 px

The class prefixes used for small phone screens, tablets, small desktop screens, and large desktop screens are .col-xs-, .col-sm-, .col-md-, and .col-lg-, respectively. The default gutter width is 30 px.

Note

Gutters are usually desirable...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime
Banner background image