User Tools

Site Tools


Sidebar

en:objects:form

form

The object is used to manage forms on the current page (FORM tag)



Sample HTML code:
<form id="123" method="post" action="" name="qwer" target=""><:form>

Description:
the FORM Tag sets the form on the web page. The form is intended for data exchange between the user and the server. The scope of forms is not limited to sending data to the server.you can use client scripts to access any form element, change it, and apply it as you like.A document can contain any number of forms, but only one form can be sent to the server at a time. For this reason, form data must be independent of each other.

To send a form to the server, use the Submit button, and you can do the same if you press Enter within the form. If the Submit button is not present in the form, the Enter key simulates its use.When the form is sent to the server, data management is passed to the program specified by the action attribute of the form tag. The browser pre-prepares information in the form of a "name=value" pair, where the name is defined by the name attribute of the input tag, and the value is entered by the user or set in the default form field. If the GET method is used to send data, the address bar can look like this : http://www.htmlbook.ru/cgi-bin/handler.cgi?nick=%C2%E0%ED%FF+%D8%E0%EF%EE%F7%EA%E8%ED&page=5

Parameters are listed after the question mark specified after the address of the CGI program and separated by an ampersand (&). non-Latin characters are converted to hexadecimal representation (in the form %HH, where HH is the hexadecimal code for the ASCII character value), and the space is replaced with a plus (+). You can put other tags inside the form container, but the form itself is not displayed on the web page in any way, only its elements and the results of nested tags are visible.

Learn more about the FORM tag (source)



basic functionality
form submission (sending data to the site)
resetting the form (returning to the default data of form elements)
Get form action (url to which form data is passed)



form Submission (sending data to the site)


submit_by_number – submit a form with the specified number
submit_by_name – submit a form with the specified name
submit_by_id – submit a form with the specified id
submit_by_action – make a form submit with the specified action
submit_by_attribute – make a form submission with the specified attribute value



Resetting the form (returning to the default data for form elements)


reset_by_number – reset the form with the specified number
reset_by_name – reset the form with the specified name



Get form action (url to which form data is passed)


get_action_by_number – get the form action with the specified number
get_action_by_name – get the form action with the specified name
get_action_by_id – get the form action with the specified id

en/objects/form.txt · Last modified: 2020/10/06 17:45 (external edit)