• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

Chapter 24. Client-side Scripting > Front and Center: Debugging

Front and Center: Debugging

So far, the assumption has been that all the JavaScript you're entering will run without problems. As long as you enter it correctly, it will, but that's because I've already debugged it for you! In the real world, code almost never runs successfully on the first try. Sometimes you get lucky and your code runs without debugging, but almost all code requires some level of debugging in order to get the desired results.

There are two types of problems you can encounter with code—syntax errors and logic errors. Syntax errors are often the easiest errors to resolve. For example, the following line of code will generate an error:


PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint