📄️ Defining Forms
Django provides some facilities for generating and validating forms, which relieve you of the task of manually writing the HTML code and the Python code responsible for verifying that the data entered is valid.
📄️ Submitting And Validating Forms
Previously we mentioned that an HTTP method is included in every request that the web browser makes to our Django application. The GET method is the most used, as it indicates that you simply want to fetch the content of a particular page. The POST method, on the other hand, indicates that you want to send data to the server. This method is the one used when working with forms (hence the method="post" attribute used in the previous section.) From a Django view you can know which HTTP method the current request includes via the request.method attribute.
📄️ Fields Types in Forms
Besides the CharField and IntegerField classes seen in the previous section, you will probably make use of the following field types.