Professional Documents
Culture Documents
Development using
Bootstrap
Param Chahal
| Updated On October 1, 2020| Tutorials Web Design, WordPress
Here is a step by step tutorial to guide you through. It will cover all the basics
to make a WordPress Bootstrap Enabled theme for your website.
We have many methods to get the best out of the combination of Bootstrap
and WordPress. Here at Templatetoaster Bootstrap builder, I am listing the
three basic methods for WordPress theme development with Bootstrap as
follows
1. Manual Coding
Let’s see the step by step procedure to include Bootstrap in WordPress using
these methods
5. To Link Bootstrap CSS file, copy below code and paste to your index.html
file under the <head> tag.
<script
src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.4/jquery.min.js
"></script>
<script src="js/bootstrap.js"></script>
That was all about linking bootstrap files to HTML.
<div class="row">
</div>
</div>
</div>
</div>
</div>
6. Now, Create the header.php file. We have taken the HTML code from
index.html (created in step A) file from the top till nav and pasted into the
header.php file as shown below.
<html>
<head>
</head>
<body>
</a>
</ul>
</div>
</nav>
7. Later, as you need to add multiple pages to your website from WordPress
Dashboard, add this code to your page.php file.
<div class="wrap">
<?php
while ( have_posts() ) : the_post(); ?>
?>
8. Similarly, create the footer.php file, taking code from the index.html file.
<div class="row">
</div>
<h5>Features</h5>
<ul class="list-unstyled text-small">
</ul>
</div>
<h5>Resources</h5>
</ul>
</div>
<h5>Resources</h5>
</div>
<h5>About</h5>
</ul>
</div>
</div>
</footer>
9. Now, create the function.php file. Mainly, you will enqueue your Bootstrap
javascript and style files with functions here as shown below
<?php
wp_register_style('bootstrap', get_stylesheet_directory_uri().
'/css/bootstrap.css');
wp_enqueue_style('bootstrap');
wp_register_style('style',
get_stylesheet_directory_uri().'/style.css');
wp_enqueue_style('style');
function my_scripts_method() {
wp_register_script('bootstrap', get_template_directory_uri() .
'/js/bootstrap.js', array('jquery'), '1.0.0', false);
wp_enqueue_script('bootstrap');;
?>
<?php
function theme_setup()
register_nav_menus(array(
));
add_action('after_setup_theme', 'theme_setup');
?>
10. You will now, write the style.css file for your theme. The example code is
here
/*
Version:1.1
Author: admin
*/
.container {
max-width: 960px;
/*
*/
.site-header {
.site-header a {
color: #999;
.site-header a:hover {
color: #fff;
text-decoration: none;
}
/*
*/
.product-device {
position: absolute;
right: 10%;
bottom: -30%;
width: 300px;
height: 540px;
background-color: #333;
border-radius: 21px;
-webkit-transform: rotate(30deg);
transform: rotate(30deg);
.product-device::before {
position: absolute;
top: 10%;
right: 10px;
bottom: 10%;
left: 10px;
content: "";
background-color: rgba(255, 255, 255, .1);
border-radius: 5px;
.product-device-2 {
top: -25%;
right: auto;
bottom: 0;
left: 5%;
background-color: #e5e5e5;
/*
* Extra utilities
*/
.flex-equal > * {
-ms-flex: 1;
-webkit-box-flex: 1;
flex: 1;
}
@media (min-width: 768px) {
.flex-md-equal > * {
-ms-flex: 1;
-webkit-box-flex: 1;
flex: 1;
nav.site-header ul li {
display: inline-block;
padding: 10px;
margin-left: 15px;
11. The theme folder shall also have the screenshot of your theme. Say it’s
screenshot.png here.
12. You are almost done. Just Activate your wpbootstraptheme theme from
WordPress Dashboard.
Appearance → Themes → Activate
13. Now, create content pages as per your requirements in the Page Editor.
Pages → Add New Page
If you want a cool alternative to coding, you can use our WordPress theme
builder. A fine software that will give a plain-sailing drag and drop
environment. You don’t have to write a single line of code. It will be just a
matter of few minutes to design your own theme. The most interesting fact is
that all the themes you design in TemplateToaster will be Bootstrap based by
default. So, no extra botherations to include Bootstrap in WordPress. You
can read our blog to get acquainted with the process of creating a WordPress
theme from scratch in TemplateToaster web design software. Just expand
the horizons of your imagination, and paint down the theme of your dreams
on the canvas of TemplateToaster !!
UnderStrap
1. Rating: 5
2. Active Installs: 5000+
WP Bootstrap Starter
1. Rating: 5
2. Active Installs: 4000+
o WordPress Themes Based on Bootstrap 3
Bootstrap Basic
1. Rating: 5
2. Active Installs: 3000+
Newp
1. Rating: 5
2. Active Installs: 1000+
Square
1. Rating: 4
2. Active Installs: 500+
Bootstrap is winning the web. It can be estimated by the fact that it is used
by 17% of all the websites. Over the short span of time, it’s popularity has
grown surprisingly. This is all because of its capability to develop responsive,
mobile-first websites. But some people still prefer Foundation. But to know
more about these two frameworks, you can read our comparison
of Bootstrap vs Foundation. With all the approaches discussed here at
Templatetoaster website builder software and WordPress website builder,
you can get best out of the amalgam of Bootstrap and WordPress. So what
are you waiting for? Start creating your own WordPress Bootstrap themes
today by following these methods!!
We would love to hear your experiences. Please share your thoughts in the
comment section below. Check out free WordPress themes.