Available:*
Library | Item Barcode | Call Number | Material Type | Item Category 1 | Status |
---|---|---|---|---|---|
Searching... | 30000004708230 | QA76.73.J39 W54 2004 | Open Access Book | Book | Searching... |
On Order
Summary
Summary
What is this book about?
JavaScript is the preferred programming language for Web page applications, letting you enhance your sites with interactive, dynamic, and personalized pages. This fully updated guide shows you how to take advantage of JavaScript's client-side scripting techniques for the newest versions of Netscape and Internet Explorer, even if you've never programmed before.
You begin with basic syntax and learn about data types and how to structure code for decision-making. Then you learn to use dates, strings, and other basic objects of JavaScript. Next, you see how to use JavaScript to manipulate objects provided by the browser, such as forms and windows. From there, you move into advanced topics like using cookies and dynamic HTML.
After you have a solid foundation, you explore dynamic generation of Web content using server-side scripting and back-end databases. And you practice what you learn by building a sample application as you go.
What does this book cover?
Here are some of the things you'll find in this book:
What types of data are used in JavaScript How to identify and correct flaws in your code Techniques for programming the browser How to use Microsoft Script Debugger and Netscape Script Debugger Ways to manage cross-browser issues How JavaScript interacts with XML and HTMLWho is this book for?
This book is for anyone who wants to learn JavaScript programming. You should have some understanding of HTML and how to create static Web pages, but no prior programming experience is necessary.
Author Notes
Paul Wilton. After an initial start as a Visual Basic applications programmer at the Ministry of Defense in the U.K., Paul found himself pulled into the Net. Having joined an Internet development company, he spent the last 5 years helping create Internet solutions and is currently working on an e-commerce website for a major British bank.
Paul's main skills are in developing web front ends using DHTML, JavaScript, VBScript, and Visual Basic, and back-end solutions with ASP, Visual Basic, and SQL Server. Currently, in between web development projects, he is learning Palm OS programming.
Table of Contents
Introduction | p. xix |
Chapter 1 Introduction to JavaScript and the Web | p. 1 |
Introduction to JavaScript | p. 1 |
Tools Needed to Create JavaScript Web Applications | p. 4 |
The [left angle bracket]script[right angle bracket] Tag and Your First Simple JavaScript Program | p. 5 |
A Brief Look at Browsers and Compatibility Problems | p. 12 |
Introducing the Trivia Quiz | p. 14 |
Summary | p. 18 |
Chapter 2 Data Types and Variables | p. 19 |
Types of Data in JavaScript | p. 19 |
Variables--Storing Data in Memory | p. 22 |
Setting Up Your Browser for Errors | p. 28 |
Using Data--Calculations and Basic String Manipulation | p. 35 |
Data Type Conversion | p. 45 |
Arrays | p. 49 |
The Trivia Quiz--Storing the Questions Using Arrays | p. 58 |
Summary | p. 61 |
Exercise Questions | p. 62 |
Chapter 3 Decisions, Loops, and Functions | p. 63 |
Decision Making--The if and switch Statements | p. 64 |
Looping--The for and while Statements | p. 84 |
Functions | p. 92 |
The Trivia Quiz--Building One of the Basic Functions | p. 97 |
Summary | p. 100 |
Exercise Questions | p. 102 |
Chapter 4 JavaScript--An Object-Based Language | p. 105 |
Object-Based Programming | p. 105 |
The JavaScript Native Objects | p. 111 |
Summary | p. 155 |
Exercise Questions | p. 156 |
Chapter 5 Programming the Browser | p. 157 |
Introduction to the Browser Objects | p. 158 |
Summary | p. 183 |
Exercise Questions | p. 185 |
Chapter 6 HTML Forms--Interacting with the User | p. 187 |
HTML Forms | p. 188 |
HTML Elements in Forms | p. 191 |
The Trivia Quiz | p. 228 |
Summary | p. 233 |
Exercises | p. 235 |
Chapter 7 Windows and Frames | p. 237 |
Frames and the window Object | p. 238 |
Opening New Windows | p. 257 |
Security | p. 270 |
Trivia Quiz | p. 271 |
Summary | p. 288 |
Exercise Questions | p. 289 |
Chapter 8 String Manipulation | p. 291 |
Additional String Methods | p. 292 |
Regular Expressions | p. 297 |
The String Object--split(), replace(), search(), and match() Methods | p. 312 |
Using the RegExp Object's Constructor | p. 322 |
The Trivia Quiz | p. 323 |
Summary | p. 330 |
Exercise Questions | p. 330 |
Chapter 9 Date, Time, and Timers | p. 333 |
World Time | p. 334 |
Timers in a Web Page | p. 347 |
The Trivia Quiz | p. 357 |
Summary | p. 363 |
Exercise Questions | p. 364 |
Chapter 10 Common Mistakes, Debugging, and Error Handling | p. 365 |
I Can't Believe I Just Did That: Some Common Mistakes | p. 365 |
Microsoft Script Debugger | p. 371 |
Netscape Debugging | p. 391 |
Error Handling | p. 400 |
Summary | p. 411 |
Exercise Questions | p. 412 |
Chapter 11 Storing Information: Cookies | p. 415 |
Baking Our First Cookie | p. 415 |
Creating a Cookie | p. 427 |
Getting a Cookie's Value | p. 431 |
Cookie Limitations | p. 437 |
Cookie Security and IE6 | p. 438 |
Summary | p. 443 |
Exercise Questions | p. 444 |
Chapter 12 Dynamic HTML in Early Browsers | p. 445 |
Style Sheets | p. 446 |
Dynamic HTML in Internet Explorer 4.0+ | p. 454 |
Dynamic HTML in Netscape Navigator 4.x | p. 489 |
Cross Browser IE 4.0+ and NN 4.x DHTML | p. 514 |
Summary | p. 519 |
Exercise Questions | p. 520 |
Chapter 13 Dynamic HTML in Modern Browsers | p. 521 |
Why Do We Need Web Standards? | p. 522 |
The Web Standards | p. 524 |
The Document Object Model | p. 527 |
Writing Cross-Browser DHTML Using the DOM | p. 557 |
Summary | p. 580 |
Exercise Questions | p. 580 |
Chapter 14 JavaScript and XML | p. 583 |
What Is XML Used for? | p. 583 |
The Basics of XML | p. 584 |
Altering the Look of Our XML | p. 602 |
Manipulating XML with JavaScript | p. 613 |
Summary | p. 624 |
Exercise Questions | p. 624 |
Chapter 15 Using ActiveX and Plug-Ins with JavaScript | p. 627 |
Checking for and Embedding Plug-Ins on Netscape Navigator | p. 628 |
Checking For and Embedding ActiveX Controls on Internet Explorer | p. 634 |
Using Plug-Ins and ActiveX Controls | p. 638 |
Summary | p. 646 |
Exercise Question | p. 647 |
Chapter 16 Server-Side Scripting with ASP | p. 649 |
What Is Server-Side Scripting? | p. 649 |
Personal Web Server (IIS) | p. 651 |
Introduction to Active Server Pages | p. 667 |
ASP Objects | p. 673 |
Trivia Quiz Goes Server-Side | p. 713 |
Summary | p. 719 |
Exercise Questions | p. 720 |
Chapter 17 Databases | p. 721 |
A Brief Guide to Databases | p. 722 |
Accessing Databases from a Web Page | p. 746 |
Trivia Quiz | p. 770 |
Summary | p. 795 |
Exercise Questions | p. 796 |
Appendix A Exercise Solutions | p. 797 |
Chapter 2 | p. 797 |
Chapter 3 | p. 799 |
Chapter 4 | p. 803 |
Chapter 5 | p. 807 |
Chapter 6 | p. 812 |
Chapter 7 | p. 818 |
Chapter 8 | p. 826 |
Chapter 9 | p. 829 |
Chapter 10 | p. 833 |
Chapter 11 | p. 836 |
Chapter 12 | p. 841 |
Chapter 13 | p. 850 |
Chapter 14 | p. 853 |
Chapter 15 | p. 856 |
Chapter 16 | p. 858 |
Chapter 17 | p. 870 |
Appendix B JavaScript Core Reference | p. 885 |
Browser Reference | p. 885 |
Reserved Words | p. 885 |
JavaScript Operators | p. 887 |
JavaScript Statements | p. 893 |
Top-Level Properties and Functions | p. 898 |
JavaScript Core Objects | p. 900 |
Appendix C JavaScript Client Reference | p. 923 |
Browser Support for JavaScript | p. 923 |
Operators | p. 924 |
Statements | p. 924 |
Events | p. 924 |
Top-Level Functions | p. 926 |
Objects | p. 926 |
Appendix D Latin-1 Character Set | p. 949 |
Index | p. 957 |