JavaScript EditorBest javascript editor debugger     Ajax website 



Main Page

Previous Page
Next Page

20. A Taste Of Javascript

Many of the most popular effects created on Web pages these days have little or nothing to do with (X)HTML and everything to do with JavaScript, a scripting language originally developed by Netscape Communications and now supported by all major browsers. There are entire booksand lots of them! that go into JavaScript in full detail. This is not one of them.

Instead, I hope to whet your appetite with a tiny sampler of very simple scripts. Hopefully, they will give you the beginning of an idea of what you can do with JavaScript. Please note that there are probably much more elegant methods of achieving these effects that make the script more flexible and more powerful. But that would require a level of JavaScript that would not fit in a book about (X)HTML. If you'd like to find out more about what you can do with JavaScript, you might try the latest edition of JavaScript for the Web: Visual QuickStart Guide, by Tom Negrino and Dori Smith or the excellent online magazine A List Apart (http://www.alistapart.com).

There are a couple of things to keep in mind while writing JavaScript. You should be very careful with spaces, returns, and all the funny punctuation. If you have trouble typing the scripts in yourself, feel free to download these examples from my Web site (see page 26). I've personally tested these scriptsand they work fineon current major browsers.


Previous Page
Next Page


      Adding the Current Date and Time
      Setting a New Window's Size
      Changing an Image When a Visitor Points
      Loading Images into Cache


JavaScript EditorBest javascript editor debugger     Ajax website 
R7