Introduction

Why This Book?

The concept for this book grew out of Robin’s extremely popular online courses in which thousands of students are enrolled. From their feedback, it became evident that the reason for this popularity was that students love the way the material is broken up into easy-to-digest lessons, each of which can be completed in an hour or less. They also like the no-nonsense, jargon-free, and friendly writing style.

Now, working together, Robin and McGraw-Hill Education have revised, updated, and developed his JavaScript course into this book, which not only will teach you everything you need to learn in 20 lessons (of less than an hour each), but it also includes an average 15-minute detailed video walk-through for each lesson, comprising 5 hours of footage in total.

Watch the videos after reading the lesson to reinforce key concepts, or use the video as a primer to working through each print lesson. Together, the book and videos make learning JavaScript easier than it has ever been, and is the ideal way for you to add JavaScript skills to your web development toolkit.

image

         To view the accompanying video for this lesson, please visit mhprofessional.com/nixonjavascript/.

Who Should Read This Book

Each chapter is laid out in a straightforward and logical manner as a lesson, with plenty of examples written using simple and clear JavaScript. Before moving on to each subsequent lesson, you have the opportunity to test your new knowledge with a set of 10 questions about what you have just learned. You can also work along with every lesson by watching its accompanying video tutorial.

Even if you have never programmed before, you will still learn everything you need from this book, because the principles behind how programming works are fully explained, and no prior knowledge is ever assumed. Between the lessons, the self-test questions, and the videos, this book will ensure that you learn the language thoroughly and quickly.

To save you typing them in, all the example files from the book are saved in a freely downloadable zip file available at the companion website: 20lessons.com.

What This Book Covers

This book covers every aspect of JavaScript, starting with basic syntax and language rules, such as where and how you can include JavaScript in your web documents. You will also learn about numeric and string variables, arrays, and objects, and how to assign, manipulate, and read values. More advanced techniques such as using hashes to index into objects and multidimensional arrays are also made easy. How to loop code and control program flow with conditional statements is explained in plain English, as well as how to create and use functions and methods in either a procedural or object-oriented manner. Important techniques such as handling mouse and keyboard events, managing cookies and local storage, and running background tasks and Ajax communication are all revealed in simple, short examples. By the time you finish the book’s 20 lessons, you’ll have a thorough grounding in JavaScript and be able to use it to dynamically enhance your web pages.

How to Use This Book

This book has been written in a logical order so that each lesson builds on information learned in the previous ones. You should begin at Lesson 1 and then work sequentially through the book, proceeding to the next lesson only when you can correctly answer the self-test questions in the previous one.

Lessons should take you less than an hour to finish, including viewing the accompanying video walk-through provided with each one. With over 5 hours of video in total, that’s an average of 15 minutes dedicated to each lesson.

How Is This Book Organized?

This book takes you right from the basics through to advanced techniques and includes the following lessons: Introduction to JavaScript, Incorporating JavaScript into a Web Page, Working with Arithmetic Operators and Functions, Applying Comparison and Logical Operators, Creating JavaScript Arrays, Accessing Multidimensional Arrays, Calling Array Functions, Pushing to and Popping from Arrays, Advanced Array Manipulation, Controlling Program Flow, Looping Sections of Code, Writing Functions, Manipulating JavaScript Objects, Handling Errors and Regular Expressions, Interacting with the Document Object Model, Inserting Inline JavaScript and Events, Controlling Cookies and Local Storage, Working with Different Browsers, Implementing Interrupts and Timeouts, and Using Ajax. Appendix A contains the answers to self-test questions, and Appendix B covers a handy reference to the most commonly used JavaScript functions and properties.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.222.166.105