Introducing Regular Expressions (eBook)
XIII, 48 Seiten
Apress (Verlag)
978-1-4842-2508-0 (ISBN)
- What regular expressions are and why you should use them
- Use useful expressions (including examples)
- Reference features and functions
- Use regular expressions in all JavaScript environments
This book is your easy-to-digest and concise guide to regular expressions in JavaScript, this book teaches you the very basics and can be used in the browser or on the server. Explore and understand how to use regular expressions in all JavaScript environments. Presented in four key concept sections, Introducing Regular Expressions shows how to create and use regular expressions to accelerate your JavaScript development.What You'll LearnWhat regular expressions are and why you should use them Use useful expressions (including examples)Reference features and functionsUse regular expressions in all JavaScript environmentsWho This Book Is For Developers of web applications who want to explore the capabilities of JavaScript based apps on both, client and server. It's suitable for beginners that have a basic understanding of JavaScript already.
Jörg Krause has been working with software and software technology since the early 1980’s, beginning with a ZX 81 and taking his first steps as a programmer in BASIC and assembly language. He studied Information Technology at Humboldt University, Berlin but left early, in the 90’s, to start his own company. He has worked with Internet Technology and software development since the early days when CompuServe and FidoNet dominated. He’s been with Microsoft technologies and software since Windows 95. In 1998, he worked on one of the first commercial e-commerce solutions, and wrote his first book in Germany, “E-Commerce and Online Marketing”, published by Carl Hanser Verlag, Munich. Due to its wide success, he started working as a freelance consultant and author in order to share his experience and knowledge with others. He has written several books for Apress, Hanser, Addison Wesley and other major publishers along with several self-published books—a total of over sixty titles. He also publishes articles in magazines and speaks at major conferences in Germany. Currently, Jörg works as an independent consultant, software developer, and author in Berlin, Germany. In his occasional spare time, Jörg enjoys reading thrillers and science fiction novels, and going on a round of golf.
Contents at a Glance 4
Contents 5
About the Author 8
Introduction 9
Chapter 1: Introducing Regular Expressions 12
Copy or Scaffold? 13
How Does It Work? 14
Resolving Expressions 15
Chapter 2: Recognizing Patterns 16
Basics 16
Characters, Lines, and Text 16
Terms for Regular Expressions 17
Metacharacters 17
Literals 17
Character Classes 17
References 18
Metacharacters Overview 18
Start, End, and Boundaries 18
Any Character 19
No Characters 20
Character Classes 20
One out of Many 20
Negations 21
Digits 21
Date and Time 22
Strings 22
Abbreviations 23
Repetition Operators 23
Common Operators 24
Summary 25
Special Operators 25
References 25
Groups 26
Simple Groups 26
Enclosing Characters 27
Non-Counting Groups 28
Lookahead References 28
Chapter 3: The JavaScript Functions 30
The RegExp Object 30
Methods 30
Properties 31
Dynamic Properties 32
The Literal Form 33
Execution Options 33
String Functions 33
Overview 34
Chapter 4: Examples of Patterns 35
Web and Network 35
HTML Tags 35
IP Addresses 36
Mac Addresses 37
URL 38
Query String 40
Port Numbers 40
Manipulating Data 41
Remove Spaces 41
Simulation of a Variable Distance 42
File Extensions 43
Non-Printable Characters 43
Hexadecimal Digits for Colors 43
Form Validation 43
eMail 43
Date Expressions 45
String Passwords 47
ISBN 48
Currencies 48
Number Ranges 48
Floating Point Numbers 49
Thousands Divider 49
Credit Cards 49
Geo Coordinates 51
Guid/UUID 52
Percentages 52
Index 56
| Erscheint lt. Verlag | 22.12.2016 |
|---|---|
| Zusatzinfo | XIII, 48 p. 35 illus., 17 illus. in color. |
| Verlagsort | Berkeley |
| Sprache | englisch |
| Themenwelt | Mathematik / Informatik ► Informatik ► Web / Internet |
| Schlagworte | ES6 • JavaScript • programming • Regular Expressions • TypeScript • Web Development • Web Programming |
| ISBN-10 | 1-4842-2508-2 / 1484225082 |
| ISBN-13 | 978-1-4842-2508-0 / 9781484225080 |
| Informationen gemäß Produktsicherheitsverordnung (GPSR) | |
| Haben Sie eine Frage zum Produkt? |
DRM: Digitales Wasserzeichen
Dieses eBook enthält ein digitales Wasserzeichen und ist damit für Sie personalisiert. Bei einer missbräuchlichen Weitergabe des eBooks an Dritte ist eine Rückverfolgung an die Quelle möglich.
Dateiformat: PDF (Portable Document Format)
Mit einem festen Seitenlayout eignet sich die PDF besonders für Fachbücher mit Spalten, Tabellen und Abbildungen. Eine PDF kann auf fast allen Geräten angezeigt werden, ist aber für kleine Displays (Smartphone, eReader) nur eingeschränkt geeignet.
Systemvoraussetzungen:
PC/Mac: Mit einem PC oder Mac können Sie dieses eBook lesen. Sie benötigen dafür einen PDF-Viewer - z.B. den Adobe Reader oder Adobe Digital Editions.
eReader: Dieses eBook kann mit (fast) allen eBook-Readern gelesen werden. Mit dem amazon-Kindle ist es aber nicht kompatibel.
Smartphone/Tablet: Egal ob Apple oder Android, dieses eBook können Sie lesen. Sie benötigen dafür einen PDF-Viewer - z.B. die kostenlose Adobe Digital Editions-App.
Buying eBooks from abroad
For tax law reasons we can sell eBooks just within Germany and Switzerland. Regrettably we cannot fulfill eBook-orders from other countries.
aus dem Bereich