The basic structure of an online form

An online form or web form always begins and ends with the form tag. The following code example shows a small form in which the first name and last name can be entered. The input fields are of “input type” and the label of the respective field is of “label type”. The form contains two buttons ( button tags) with which you can reset the entered data (Reset) or submit it (Submit). When you click on the Submit button, the page defined under action is called up. This page then takes over the further processing of the data. These are often PHP pages.

<form action="send.html" id="contact">
<label class="h2" form="person">Name</label>
<label for="firstname">First name</label>
<input type="text" name="firstname" id="firstname">
<label for="surname">Last name</label>
<input type="text" name="surname" id="surname">
<button type="reset">Reset</button>
<button type="submit">Submit Now</button>

In addition, there are many other HTML tags and attributes for special data fields of an Internet form, such as textarea, select, option, etc. These data fields are often additionally combined with JavaScript, whereby various checks of the entered values take place on the browser side, i.e. before the form data is sent.

Creating an online form

The basic framework for creating an online form is given above. With a little HTML experience, you can create your own form. However, you will quickly reach the limits of effectiveness if you want to create the entire form, including design adjustments, by hand. The best way to create an online form is to use a suitable tool such as the HeyForm form builder or to obtain ready-made form templates from internet services.