Download presentation
Presentation is loading. Please wait.
Published byRalph Murphy Modified over 9 years ago
1
Client-Side Validation with Javascript by Daniel Yee
2
Client-Side Scripting Language Javascript European Computer Manufacturers Association (ECMA) ECMA-262 Third edition Updated Last December 1999
3
Javascript Not a full fledged programming language Cannot connect to databases Limited interactions to system resources Cannot do tasks most web databases require
4
Common Uses of Javascript Validation of data Simple interaction with data Adding dynamic elements to web page
5
Benefits of using Javascript Faster response then using server-side validation Reduction in web-server load Reduction in network traffic Can be saved as a file - file.js and reused by typing
6
Warning!!!!!!!!!!!!! Never rely on client-side validation as the only method of ensuring requirements and constraints Javascript can be bypassed by the user through design, error, or configuration
7
Validating Data Simple example for validating a with JavaScriptexample Check for whitespace
8
Batch Error Reporting Validation for multiple fields Batch error reporting Example
9
Interactive Validation Password validation Example
10
Dynamic Elements Some implementations not associated with web database applications MouseOver Prefilled calculations
11
MouseOver Creating a mouseOver Event Example
12
Prefilled Calculations Shopping cart updating Example
13
Conclusion Javascript is a client-side scripting language Can be used for validating forms and enhancing user interactions Benefits include improved speed, reduced load, and added features
14
REMEMBER!!!!! NEVER USE AS THE ONLY METHOD TO ENSURE REQUIREMENTS, SECURITY, AND CONSTRAINTS WHY? BECAUSE IT CAN BE BYPASSED BY THE USER
15
The End
Similar presentations
© 2024 SlidePlayer.com Inc.
All rights reserved.