HTML code
This is the html code used to create this bootstrap snippet, You can copy and paste the following html code inside a page with bootstrap 5.1.3 included, to get the result that you can see in the preview selection
Download<div class="container-fluid">
<div class="container">
<!-- Title -->
<div class="d-flex justify-content-between align-items-lg-center py-3 flex-column flex-lg-row">
<h2 class="h5 mb-3 mb-lg-0"><a href="../../pages/admin/customers.html" class="text-muted"><i class="bi bi-arrow-left-square me-2"></i></a> Create new customer</h2>
<div class="hstack gap-3">
<button class="btn btn-light btn-sm btn-icon-text"><i class="bi bi-x"></i> <span class="text">Cancel</span></button>
<button class="btn btn-primary btn-sm btn-icon-text"><i class="bi bi-save"></i> <span class="text">Save</span></button>
</div>
</div>
<!-- Main content -->
<div class="row">
<!-- Left side -->
<div class="col-lg-8">
<!-- Basic information -->
<div class="card mb-4">
<div class="card-body">
<h3 class="h6 mb-4">Basic information</h3>
<div class="row">
<div class="col-lg-6">
<div class="mb-3">
<label class="form-label">First name</label>
<input type="text" class="form-control">
</div>
</div>
<div class="col-lg-6">
<div class="mb-3">
<label class="form-label">Last name</label>
<input type="text" class="form-control">
</div>
</div>
</div>
<div class="row">
<div class="col-lg-6">
<div class="mb-3">
<label class="form-label">Email</label>
<input type="email" class="form-control">
</div>
</div>
<div class="col-lg-6">
<div class="mb-3">
<label class="form-label">Phone number</label>
<input type="text" class="form-control">
</div>
</div>
</div>
</div>
</div>
<!-- Address -->
<div class="card mb-4">
<div class="card-body">
<h3 class="h6 mb-4">Address</h3>
<div class="mb-3">
<label class="form-label">Address Line 1</label>
<input type="text" class="form-control">
</div>
<div class="mb-3">
<label class="form-label">Address Line 2</label>
<input type="text" class="form-control">
</div>
<div class="row">
<div class="col-lg-6">
<div class="mb-3">
<label class="form-label">Country</label>
<select class="select2 form-control select2-hidden-accessible" data-select2-placeholder="Select country" data-select2-id="select2-data-1-gy14" tabindex="-1" aria-hidden="true">
<option data-select2-id="select2-data-3-ibs9"></option>
<option value="AF">Afghanistan</option>
<option value="BS">Bahamas</option>
<option value="KH">Cambodia</option>
<option value="DK">Denmark</option>
<option value="TL">East Timor</option>
<option value="GM">Gambia</option>
</select><span class="select2 select2-container select2-container--bootstrap-5" dir="ltr" data-select2-id="select2-data-2-46y9" style="width: 391px;"><span class="selection"><span class="select2-selection select2-selection--single" role="combobox" aria-haspopup="true" aria-expanded="false" tabindex="0" aria-disabled="false" aria-labelledby="select2-vp8l-container" aria-controls="select2-vp8l-container"><span class="select2-selection__rendered" id="select2-vp8l-container" role="textbox" aria-readonly="true" title="Select country"><span class="select2-selection__placeholder">Select country</span></span><span class="select2-selection__arrow" role="presentation"><b role="presentation"></b></span></span></span><span class="dropdown-wrapper" aria-hidden="true"></span></span>
</div>
</div>
<div class="col-lg-6">
<div class="mb-3">
<label class="form-label">State</label>
<select class="select2 form-control select2-hidden-accessible" data-select2-placeholder="Select state" data-select2-id="select2-data-4-680y" tabindex="-1" aria-hidden="true">
<option data-select2-id="select2-data-6-cshs"></option>
<option value="AL">Alabama</option>
<option value="CA">California</option>
<option value="DE">Delaware</option>
<option value="FL">Florida</option>
<option value="GA">Georgia</option>
<option value="HI">Hawaii</option>
<option value="ID">Idaho</option>
<option value="KS">Kansas</option>
</select><span class="select2 select2-container select2-container--bootstrap-5" dir="ltr" data-select2-id="select2-data-5-np4c" style="width: 391px;"><span class="selection"><span class="select2-selection select2-selection--single" role="combobox" aria-haspopup="true" aria-expanded="false" tabindex="0" aria-disabled="false" aria-labelledby="select2-2fn7-container" aria-controls="select2-2fn7-container"><span class="select2-selection__rendered" id="select2-2fn7-container" role="textbox" aria-readonly="true" title="Select state"><span class="select2-selection__placeholder">Select state</span></span><span class="select2-selection__arrow" role="presentation"><b role="presentation"></b></span></span></span><span class="dropdown-wrapper" aria-hidden="true"></span></span>
</div>
</div>
</div>
<div class="row">
<div class="col-lg-6">
<div class="mb-3">
<label class="form-label">City</label>
<select class="select2 form-control select2-hidden-accessible" data-select2-placeholder="Select city" data-select2-id="select2-data-7-809c" tabindex="-1" aria-hidden="true">
<option data-select2-id="select2-data-9-k35n"></option>
<option value="b">Bangkok</option>
<option value="d">Dubai</option>
<option value="h">Hong Kong</option>
<option value="k">Kuala Lumpur</option>
<option value="l">London</option>
<option value="n">New York City</option>
<option value="m">Macau</option>
<option value="p">Paris</option>
</select><span class="select2 select2-container select2-container--bootstrap-5" dir="ltr" data-select2-id="select2-data-8-3peu" style="width: 391px;"><span class="selection"><span class="select2-selection select2-selection--single" role="combobox" aria-haspopup="true" aria-expanded="false" tabindex="0" aria-disabled="false" aria-labelledby="select2-jdfi-container" aria-controls="select2-jdfi-container"><span class="select2-selection__rendered" id="select2-jdfi-container" role="textbox" aria-readonly="true" title="Select city"><span class="select2-selection__placeholder">Select city</span></span><span class="select2-selection__arrow" role="presentation"><b role="presentation"></b></span></span></span><span class="dropdown-wrapper" aria-hidden="true"></span></span>
</div>
</div>
<div class="col-lg-6">
<div class="mb-3">
<label class="form-label">ZIP code</label>
<input type="text" class="form-control">
</div>
</div>
</div>
</div>
</div>
</div>
<!-- Right side -->
<div class="col-lg-4">
<!-- Status -->
<div class="card mb-4">
<div class="card-body">
<h3 class="h6">Status</h3>
<select class="form-select">
<option value="draft" selected="">Draft</option>
<option value="active">Active</option>
<option value="active">Inactive</option>
</select>
</div>
</div>
<!-- Avatar -->
<div class="card mb-4">
<div class="card-body">
<h3 class="h6">Avatar</h3>
<input class="form-control" type="file">
</div>
</div>
<!-- Notes -->
<div class="card mb-4">
<div class="card-body">
<h3 class="h6">Notes</h3>
<textarea class="form-control" rows="3"></textarea>
</div>
</div>
<!-- Notification settings -->
<div class="card mb-4">
<div class="card-body">
<h3 class="h6">Notification Settings</h3>
<ul class="list-group list-group-flush mx-n2">
<li class="list-group-item px-0 d-flex justify-content-between align-items-start">
<div class="ms-2 me-auto">
<h6 class="mb-0">News and updates</h6>
<small>News about product and feature updates.</small>
</div>
<div class="form-check form-switch">
<input class="form-check-input" type="checkbox" role="switch">
</div>
</li>
<li class="list-group-item px-0 d-flex justify-content-between align-items-start">
<div class="ms-2 me-auto">
<h6 class="mb-0">Tips and tutorials</h6>
<small>Tips on getting more out of the platform.</small>
</div>
<div class="form-check form-switch">
<input class="form-check-input" type="checkbox" role="switch" checked="">
</div>
</li>
<li class="list-group-item px-0 d-flex justify-content-between align-items-start">
<div class="ms-2 me-auto">
<h6 class="mb-0">User Research</h6>
<small>Get involved in our beta testing program.</small>
</div>
<div class="form-check form-switch">
<input class="form-check-input" type="checkbox" role="switch">
</div>
</li>
</ul>
</div>
</div>
</div>
</div>
</div>
</div>
CSS code
This is the css code used to create this bootstrap snippet, You can copy and paste the following css code inside a page with bootstrap 5.1.3 included, to get the result that you can see in the preview selection
Downloadbody{
background:#eee;
}
.card {
box-shadow: 0 20px 27px 0 rgb(0 0 0 / 5%);
}
.card {
position: relative;
display: flex;
flex-direction: column;
min-width: 0;
word-wrap: break-word;
background-color: #fff;
background-clip: border-box;
border: 0 solid rgba(0,0,0,.125);
border-radius: 1rem;
}
.card-body {
-webkit-box-flex: 1;
-ms-flex: 1 1 auto;
flex: 1 1 auto;
padding: 1.5rem 1.5rem;
}
About this bootstrap example/template
This example/template, Create new customer form, was published on Jan 31st 2022, 08:33 by Bootdey Admin and it is free.
We hope you will enjoy this awesome snippet and stay tuned for the latest updates, bootdey snippets are already used in thousands of blogs, websites and projects. We believe it will save your precious time and gives trendy look to your next web project.
We always try to offer the best beautiful and responsive source of Bootstrap code examples and components.
This code example currectly have 13.6K views, Using this bootstrap snippet you have the following benefits:
Bootstrap 5.1.3
<link rel='stylesheet' href='https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css'>
<script src='https://cdn.jsdelivr.net/npm/[email protected]/dist/js/bootstrap.bundle.min.js'></script>
This code example is based on bootstrap 5.1.3 and the grid system of this framework
Responsive
Based on bootstrap framework makes all the layouts perfectly responsive for all devices
Crossbrowser compatibility
Tested on all major browsers, it works smoothly on all of them
semantic html 5
Built on html / css3 the code quality is really amazing
Simple Integration
This code example can be simply integrated on existing sites and new ones too, all you need to do is copy the code and start working