"Deliciousapp">"UTF-8"> "formctr"> "Applyform"Novalidate> class="P-input"> "text"Placeholder="Please enter your name"Name="Delicacyname"Ng-model="name"Ng-minlength="2"Ng-maxlength="6"Required/> class="P-input"> "text"Placeholder="Please enter your phone number"Name="Mobilephone"Ng-model="Mobile"ng-pattern="/^1[3|4|5|7|8][0-9]\d{8}$/"Required/> "applyform.delicacyname. $error"ng-show="applyform.delicacyname. $touched | | applyform. $submitted"> "Required" class="Apply-error"> name cannot be empty
What is Bootstrap?
Bootstrap is a front-end framework for rapid development of Web applications and Web sites. Bootstrap is based on HTML, CSS, and JAVASCRIPT.
the layout of a form is divided into two types: Automatic layout and custom layout.
Automatic layout is the automatic use of different
Bootstrap provides three form layouts: vertical forms, inline forms, and horizontal forms. The following one to introduce you, interested friends to study together.
To create a vertical or basic form:
Add role= "Form" to the parent Put labels and controls in a Add class to all text elements
Inline
Use the bootstrapValidator plug-in to dynamically add and verify form elements, and use bootstrap to verify the form.
I. Preface
In practice, to dynamically add form elements, and use the bootstrapValidator plug-in to perform foreground verification on Dynamically added form
In bootstrap, what is the role of form attribute role = "form ?, Bootstraprole
In essence, the role in html enhances semantics. When the existing HTML tags cannot fully express semantics, they can be explained by role. This usually occurs on some custom components, which can enhance the accessibility, availability and interactivity of the components.Role is used
an element
Extendattr:{key:value} a key-value pair form that only supports HTML5 data-generates a data-prefix on the element
Demo:extendattr:{select:true} will generate a Data-select=true extended property on the element
Group form configuration: ' Group name ': []
Demo: ' Personal information ': [{},{}]
The above is a small set to introduce the Bootstrap i
The effect diagram looks like this:
The implementation code is as follows:
The above is a small part of the introduction of the bootstrap implementation of Drop-down menu items and form navigation bar (two menu items, a drop-down menu and login Form navigation bar), I hope to help you, if you have any questions please give me a message, small series
This article mainly introduces the use of bootstrap form style knowledge, very good, together to see!
Form
Effect Chart:
Class:form-control
1, width into 100%, 2, set a light gray (#ccc) border, 3, with 4px fillet, 4, set the shadow effect, and the element gets focus, shadow and border effects will change, 5, set the placeholder color for #999
The most common elements of a form include text entry boxes, Drop-down selection boxes, radio boxes, check boxes, text fields, buttons, and so on. Here are the different versions of Bootstrap:
LESS:forms.less
SASS: _forms.scss
Bootstrap only customize the fieldset, legend, label labels within the form
fields
This article will mainly introduce the use of bootstrap forms.
1.Bootstrap Base Form
Common elements in a form include text-entry boxes, Drop-down selection boxes, radio buttons, check buttons, text fields, and buttons.
Let's take a look at a basic form:
Th
will be explained in detail in the Bootstrap plugin section.
Customization: You can customize Bootstrap components, less variables, and jQuery plug-ins to get your own version.
In the project we can often see like provinces and counties to choose, in fact, there are many ways to implement, the following small series to introduce bootstrap intelligent
Describes how to develop a bubble style Form validation component based on jQuery. validate and Bootstrap tooltip. validatemediltip
Form Verification is a common requirement in page development. We believe that each front-end developer has experience in this field. There are many mature form verification frameworks on
The form controls supported by Bootstrap are as follows:
Bootstrap supports the most common form controls, mainly input, textarea, checkbox, Radio, and select.
Enter box (input)
The most common form text fields are input box inputs. Users can enter most of the necessary
This article is mainly about the form, this is actually for people who have done the site, is not unfamiliar, and can be said to be the most commonly used to submit data form form. This article mainly to explain the content:
1. Basic cases2. Inline form3. Horizontally arranged forms4. Supported controls5. Static controls6. Control state7. Control Dimensions8. He
This is probably a convention, learning the front desk backstage the first contact business is the user registration and login. Now the community adhere to the concept of people-oriented, the same is true in the Web development process. User is our face more objects, but also the core object. The beginning of the user registration and landing this piece, is particularly important.
User registration and login are often more difficult than we think. For example, the
Form checking is a very common type of requirement in page development and is believed to be experienced by every front-end developer. There are a lot of mature form verification framework on the Internet, although it doesn't have much problem with the default design, but in practice, the form checksum can have more complex personalization requirements, so we can
This article knowledge points from http://www.runoob.com/bootstrap/bootstrap-forms.html, which wrote a more detailed example, here summed up the key to facilitate memory.
One, form layout
1. Vertical form (default)
Add role= "Form" to the parent Put the labels and control
The bootstrap set in the background can satisfy most of the style requirements. there is a form submission problem, which sets the template provided by the existing bootstrap. The code is as follows amp; lt; divclass quot; container quot; amp; gt; {code ...} there is no introduction to the form verification method
-label", has the effect of text right alignment. If you do not add this, label and input will appear to be misaligned.
Form size
The input size is controlled by "Input-sm", "INPUT-LG", which makes the input input box look smaller or larger than normal. Corresponding to this is the size of the Chinese label. You need to add "form-group-sm" and "FORM
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.