TAILIEUCHUNG - Publishing AJAX and PHP - part 13

4 AJAX Form Validation Validating input data is an essential requirement for quality and secure software applications. In the case of web applications, validation is an even more sensitive area, because your application is widely reachable by many users with varying skill sets and intentions. Validation is not something to play with, because invalid data has the potential to harm the application's functionality, and even corrupt the application's most sensitive area: the database. Input data validation means checking whether the data entered by the user complies with previously defined rules, which are established according to the business rules of your application. For. | 4 AJAX Form Validation Validating input data is an essential requirement for quality and secure software applications. In the case of web applications validation is an even more sensitive area because your application is widely reachable by many users with varying skill sets and intentions. Validation is not something to play with because invalid data has the potential to harm the application s functionality and even corrupt the application s most sensitive area the database. Input data validation means checking whether the data entered by the user complies with previously defined rules which are established according to the business rules of your application. For example if you require dates to be entered in the YYYY-MM-DD format then a date of February 28 would be considered invalid. Email addresses and phone numbers are other examples of data that should be checked against valid formats. Carefully define the input data validation rules in the software requirements document of the application you re developing and then use them consistently to validate your data Historically web form validation was implemented mostly at the server side after the form was submitted. In some cases there was also some JavaScript code on the client that performed simple validation such as checking whether the email address was valid or if a user name had been entered. The problems encountered with traditional web form validation techniques are Server-side form validation meets the limits of the HTTP protocol which is a stateless protocol. Unless special code is written to deal with this issue after submitting a page containing invalid data the user is shown back an empty form that has to be filled from scratch. When submitting the page the user needs to wait for a full page reload. For every mistake that is made when filling the form a new page reload happens. In this chapter we will create a form-validation application that implements the good old traditional techniques and adds an

TỪ KHÓA LIÊN QUAN
TAILIEUCHUNG - Chia sẻ tài liệu không giới hạn
Địa chỉ : 444 Hoang Hoa Tham, Hanoi, Viet Nam
Website : tailieuchung.com
Email : tailieuchung20@gmail.com
Tailieuchung.com là thư viện tài liệu trực tuyến, nơi chia sẽ trao đổi hàng triệu tài liệu như luận văn đồ án, sách, giáo trình, đề thi.
Chúng tôi không chịu trách nhiệm liên quan đến các vấn đề bản quyền nội dung tài liệu được thành viên tự nguyện đăng tải lên, nếu phát hiện thấy tài liệu xấu hoặc tài liệu có bản quyền xin hãy email cho chúng tôi.
Đã 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.