content logo

Bootstrap Toggle Switches:

Toggle Switch for Trial Product using Bootstrap

We are introducing an attractive bootstrap with functional performance. You can use this code if you have a website for selling products. The Toggle Switch for Trial Product using Bootstrap is presented in this post with a beautiful design. Most online shops use this kind of code to display their new products. In this Pure CSS Toggle Switch, you can see the specifications of the new product, and the user looks at this code and waits to purchase that supply. This Switch Button Code can be presented monthly or yearly.

There is a preview of this code here, and you can see its outstanding performance. These HTML Toggle Switches have a simple style with white background. The writings of this code are clack, and the product's price is bold. You can select if you like to choose monthly or yearly. This part is available in a line that changes to blue when you choose it. The discount amount is shown with a red theme at the bottom of the toggle. If you want to start the trial, you can choose. This section has a black background with white writing. The checkmarks of this Bootstrap Stylish Toggle Switch are presented with green color.

#

HTML Toggle Switches

#

Pure CSS Toggle Switch

#

Switch Button Code

#

Bootstrap Stylish Toggle Switch

<!-- This script got from frontendfreecode.com -->
<div class="container height-100 d-flex justify-content-center align-items-center">
    <div class="card">
        <div class="p-3 py-5">
            <div class="d-flex justify-content-between align-items-center"> <span class="text-uppercase views">100k Pageviews</span>
                <div class="price"> <span>$16.00</span> <span>/month</span> </div>
            </div>
            <div class="mt-2"> <input type="range" class="form-range" id="customRange1"> </div>
            <div class="mt-2 text-center">
                <div class="form-check form-switch flex-row d-flex align-items-center"> <label>Monthly</label> <input class="form-check-input ms-2" type="checkbox" id="flexSwitchCheckDefault"> <label class="form-check-label ms-2" for="flexSwitchCheckDefault">Yearly</label> <span class="badge-orange">10% discount</span> </div>
            </div>
        </div> <span class="border-bottom"></span>
        <div class="p-3 d-flex justify-content-between align-items-center py-4">
            <div class="d-flex flex-column">
                <div class="d-flex align-items-center"> <i class='bx bx-check text-success'></i> <span class="ms-1">Unlimited websites</span> </div>
                <div class="d-flex align-items-center"> <i class='bx bx-check text-success'></i> <span class="ms-1">100% Data Ownership</span> </div>
                <div class="d-flex align-items-center"> <i class='bx bx-check text-success'></i> <span class="ms-1">Email Reports</span> </div>
            </div> <button class="btn btn-dark h-100">Start My Trial</button>
        </div>
    </div>
</div><a style="font-size: 8pt; text-decoration: none" target="_blank" href="http://frontendfreecode.com">Free Frontend</a>
                                                                            
body {
    background-color: #f1f5fe
}
.height-100 {
    height: 100vh
}
.views {
    font-size: 13px;
    margin-top: 7px
}
.card {
    width: 400px;
    border: none;
    border-radius: 4px
}
.price span:nth-child(1) {
    font-weight: 700;
    font-size: 24px
}
.price span:nth-child(2) {
    font-weight: 300;
    font-size: 14px
}
.badge-orange {
    height: 20px;
    width: 89px;
    margin-left: 10px;
    padding-bottom: 3px;
    background-color: red;
    font-size: 13px;
    color: #fff;
    border-radius: 5px;
    display: flex;
    justify-content: center;
    align-items: center
}
<link href='https://cdn.jsdelivr.net/npm/bootstrap@5.0.0-beta1/dist/css/bootstrap.min.css' rel='stylesheet'>
<link href='https://cdn.jsdelivr.net/npm/boxicons@latest/css/boxicons.min.css' rel='stylesheet'>
<script type='text/javascript' src='https://cdn.jsdelivr.net/npm/bootstrap@5.0.0-beta1/dist/js/bootstrap.bundle.min.js'></script>
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<!-- This script got from frontendfreecode.com -->

<link href='https://cdn.jsdelivr.net/npm/bootstrap@5.0.0-beta1/dist/css/bootstrap.min.css' rel='stylesheet'>
<link href='https://cdn.jsdelivr.net/npm/boxicons@latest/css/boxicons.min.css' rel='stylesheet'>
<script type='text/javascript' src='https://cdn.jsdelivr.net/npm/bootstrap@5.0.0-beta1/dist/js/bootstrap.bundle.min.js'></script>
<style>
body {
    background-color: #f1f5fe
}
.height-100 {
    height: 100vh
}
.views {
    font-size: 13px;
    margin-top: 7px
}
.card {
    width: 400px;
    border: none;
    border-radius: 4px
}
.price span:nth-child(1) {
    font-weight: 700;
    font-size: 24px
}
.price span:nth-child(2) {
    font-weight: 300;
    font-size: 14px
}
.badge-orange {
    height: 20px;
    width: 89px;
    margin-left: 10px;
    padding-bottom: 3px;
    background-color: red;
    font-size: 13px;
    color: #fff;
    border-radius: 5px;
    display: flex;
    justify-content: center;
    align-items: center
}
</style>

</head>
<body>
<div class="container height-100 d-flex justify-content-center align-items-center">
    <div class="card">
        <div class="p-3 py-5">
            <div class="d-flex justify-content-between align-items-center"> <span class="text-uppercase views">100k Pageviews</span>
                <div class="price"> <span>$16.00</span> <span>/month</span> </div>
            </div>
            <div class="mt-2"> <input type="range" class="form-range" id="customRange1"> </div>
            <div class="mt-2 text-center">
                <div class="form-check form-switch flex-row d-flex align-items-center"> <label>Monthly</label> <input class="form-check-input ms-2" type="checkbox" id="flexSwitchCheckDefault"> <label class="form-check-label ms-2" for="flexSwitchCheckDefault">Yearly</label> <span class="badge-orange">10% discount</span> </div>
            </div>
        </div> <span class="border-bottom"></span>
        <div class="p-3 d-flex justify-content-between align-items-center py-4">
            <div class="d-flex flex-column">
                <div class="d-flex align-items-center"> <i class='bx bx-check text-success'></i> <span class="ms-1">Unlimited websites</span> </div>
                <div class="d-flex align-items-center"> <i class='bx bx-check text-success'></i> <span class="ms-1">100% Data Ownership</span> </div>
                <div class="d-flex align-items-center"> <i class='bx bx-check text-success'></i> <span class="ms-1">Email Reports</span> </div>
            </div> <button class="btn btn-dark h-100">Start My Trial</button>
        </div>
    </div>
</div><div id="bcl"><a style="font-size:8pt;text-decoration:none;" href="http://www.devanswer.com">Free Frontend</a></div>

</body>
</html>
Preview