tailieunhanh - Lecture Web technologies and programming – Lecture 10: HTML forms

Lecture Web technologies and programming – Lecture 10: HTML forms. After studying this chapter you will be able to understand: Creating tables in HTML, table attributes, page lay-out using tables, HTML forms, HTML form elements. | 1 CIIT-Human Computer Interaction-CSC456-Fall-2015-Mr. Tehseen Riaz Abbasi 1 2 3 Department of Computer Science, CIIT Islamabad. 3 4 Creating tables in HTML Table attributes Table level attributes Row level attributes Cell level attributes Page lay-out using tables HTML FORMS HTML FORM elements 5 5 Department of Computer Science, CIIT Islamabad. HTML forms are used to collect user input. HTML forms contain form elements. Form elements are different types of input elements, checkboxes, radio buttons, submit buttons, and more. 6 The element defines an HTML form: . form elements . 7 Forms provide a means of submitting information from the client to the server HTML supports tags for creating forms, however, it does not process the information Use server-side script to process form information Server-side script runs on the Web server and receives data from a form and uses it to perform a set of tasks 8 This figure shows how a Web page form interacts with a CGI script. 9 tag is used to start a form tag is used to end a form Between and , form elements are placed We can declare a form as: form elements and layout tags A single page can include several different forms, but you cannot nest one form inside another 10 Common Form Attributes: action - gives the URL of the application that is to receive and process the forms data method - sets the HTTP method that the browser uses to send the forms data to the server for processing; Either POST or GET name – name of the form 11 When to Use GET? You can use GET (the default method): If the form submission is passive (like a search engine query), and without sensitive information. When you use GET, the form data will be visible in the page address. 12 When to Use POST? You should use POST: If the form is updating data, or includes sensitive information (password). POST offers better security because the submitted data is not visible in the page . | 1 CIIT-Human Computer Interaction-CSC456-Fall-2015-Mr. Tehseen Riaz Abbasi 1 2 3 Department of Computer Science, CIIT Islamabad. 3 4 Creating tables in HTML Table attributes Table level attributes Row level attributes Cell level attributes Page lay-out using tables HTML FORMS HTML FORM elements 5 5 Department of Computer Science, CIIT Islamabad. HTML forms are used to collect user input. HTML forms contain form elements. Form elements are different types of input elements, checkboxes, radio buttons, submit buttons, and more. 6 The element defines an HTML form: . form elements . 7 Forms provide a means of submitting information from the client to the server HTML supports tags for creating forms, however, it does not process the information Use server-side script to process form information Server-side script runs on the Web server and receives data from a form and uses it to perform a set of tasks 8 This figure shows how a Web page form interacts with a CGI .

crossorigin="anonymous">
Đã phát hiện trình chặn quảng cáo AdBlock
Trang web này phụ thuộc vào doanh thu từ số lần hiển thị quảng cáo để tồn tại. Vui lòng tắt trình chặn quảng cáo của bạn hoặc tạm dừng tính năng chặn quảng cáo cho trang web này.