Bootstrap Themes
This article will demonstrate how to create a Bootstrap theme from scratch.
We’ll start with a simple HTML page and gradually add additional components until we have a fully functional, personalized, and responsive website.
The end result will look like this, and you are free to change, save, share, use, or do whatever you want with it.
We’ll begin with the following HTML page:
Bootstrap Theme Simply Me
Who Am I?
I'm an adventurer
Add Bootstrap CDN and a link to jQuery, then place HTML components inside a container:
Bootstrap Theme Simply Me
Who Am I?
I'm an adventurer
1. Add a custom class (.bg-1) to the container to change the background color.
2. Use the .text-center class to center the text within the container:
Who Am I?
I'm an adventurer
Use the .img-circle class to transform the picture into a circle.

Add more content and place it in new containers.
Who Am I?
I'm an adventurer
What Am I?
Lorem ipsum..
Where To Find Me?
Lorem ipsum..
Let’s make the containers seem better by adding some padding.
Add three equal-width columns inside the third container (.col-sm-4):
Where To Find Me?
Lorem ipsum..
Lorem ipsum..
Lorem ipsum..
Add the .img-responsive class to all images.
To center the first image, add display:inline (the .img-responsive class adds display:block, which causes the image to bounce to the left of the screen).
If you want the image to fill the entire width of the screen as it begins to stack, set width:100% to the image.
When opening the example, remember to resize the screen to observe the responsive effect.

Use CSS to alter the navigation bar:
.navbar {
padding-top: 15px;
padding-bottom: 15px;
border: 0;
border-radius: 0;
margin-bottom: 0;
font-size: 12px;
letter-spacing: 5px;
}
.navbar-nav li a:hover {
color: #1abc9c !important;
}
Create a footer and use CSS to style it.
Personalize your theme by selecting a typeface that you prefer. We used “Montserrat” from Google Font Library.
Refer to the font in the <head> section.
<link href=”https://fonts.googleapis.com/css?family=Montserrat”, rel=”stylesheet”>
Then you can use it in the page.
body {
font: 20px "Montserrat", sans-serif;
line-height: 1.8;
color: #f5f6f7;
}
p {font-size: 16px;}
We have also designed a “helper” margin class to add extra space where we believe it is needed, usually after each <h3> and <img> element.
.margin {margin-bottom: 45px;}
CodingAsk.com is designed for learning and practice. Examples may be made simpler to aid understanding. Tutorials, references, and examples are regularly checked for mistakes, but we cannot guarantee complete accuracy. By using CodingAsk.com, you agree to our terms of use, cookie, and privacy policy.
Copyright 2010-2024 by Refsnes Data. All Rights Reserved.