Skip to Content
Oracle® Web Application Programming for PL/SQL® Developers
book

Oracle® Web Application Programming for PL/SQL® Developers

by Susan Boardman, Melanie Caffrey, Solomon Morse, Benjamin Rosenzweig
December 2002
Intermediate to advanced
745 pages
17h 26m
English
Pearson
Content preview from Oracle® Web Application Programming for PL/SQL® Developers

Unit 14.2. Regular Expressions in Form Validation

The JavaScript validation script discussed in Unit 14.1 tests only for an empty value in the case of text fields. This is not a very stringent form validation. A space in the text field would be enough to pass this script’s validation test. Stricter validation is usually more desirable so that as much validation is done on the front-end as possible. Other things that could be checked are:

  1. Whether a field exceeds its maximum length.

  2. Whether only numbers were entered into the Phone Number field.

  3. Whether only text was entered in the First Name and Last Name fields.

Writing the code to test for the length is possible with the JavaScript introduced so far in this book. However, to check if only numbers ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Java™ Oracle® Database Development

Java™ Oracle® Database Development

David J. Gallardo
The Java EE 6 Tutorial: Basic Concepts, Fourth Edition

The Java EE 6 Tutorial: Basic Concepts, Fourth Edition

Eric Jendrock, Ian Evans, Devika Gollapudi, Kim Haase, Chinmayee Srivathsa
Oracle® PL/SQL® Interactive Workbook, Second Edition

Oracle® PL/SQL® Interactive Workbook, Second Edition

Benjamin Rosenzweig, Elena Silvestrova

Publisher Resources

ISBN: 0130477311Purchase book