1. Computing

Learn to Write Your Own JavaScript

By

You can only do so much to enhance your web site using JavaScripts written by someone else. Eventually you will need to learn how to write your own in order to provide some functionality not catered for by scripts that you can copy. These tutorials cover a wide range of different aspects of JavaScript and should get you started on the way toward writing your own scripts.
  1. JavaScript for Beginners
  2. Annotated Scripts
  3. Validate Form Content
  4. Animation
  1. Popup Windows
  2. Learn Ajax
  3. Controls and Widgets
  4. Bookmarklets and User Scripts

JavaScript for Beginners

You do not need prior programming experience to be able to follow this tutorial series that takes you step by step through how to write your own JavaScript programs. No longer will you have to rely on pre-built scripts written by others. You will be able to write your own scripts that do exactly what you want them to do.

Annotated Scripts

One way of learning JavaScript is to examine existing scripts to see how they work. Of course if the code is too far beyond your current knowledge of JavaScript you will still be left asking why the code is written the way it is and why that code manages to produce the end result. To make it easier for you, here are some real scripts along with descriptions of exactly what the pieces of code do and what they are there fore.

Validate Form Content

You can validate what your visitors enter into fields on your form both when they enter the field itself and immediately before they submit the form. Regular Expressions are one of the more difficult to understand parts of the JavaScript language if you do not know what the different codes mean.

Animation

Learn how to put DHTML animations onto your web page with this series of tutorials. We will start by looking at how we can make objects appear and disappear and the progress to cover how we can make the objects move about on the page. You may also want to learn more about the Document Object Model which is how JavaScript interacts with the web page.

Popup Windows

JavaScript doesn't have as much access to control the browser now as it did in the past. These tutorials look at what you can do with windows and frames using JavaScript as well as things which the browsers may treat as suggestions or disregard completely.

Learn Ajax

Being able to access information from the server without having to reload the web page will enhance your visitor's experience of your page. This series of tutorials will introduce you to Ajax by taking you step by step through the code of a simple example. Of course you will then need to use the Document Object Model to update your page with the new content that the Ajax call returns.

Controls and Widgets

Add JavaScript controls and widgets such as slideshows and hypertext popups to enhance your visitor's interaction with your page.

Bookmarklets and User Scripts

Bookmarklets (or favelets as some call them) are JavaScripts that are attached to the bookmarks or favorites menu of your browser. This allows you to run your own JavaScript on any web page that you view by selecting the bookmarklet. User scripts go one step further by allowing you to have scripts that run automatically against the web pages that you view.

©2014 About.com. All rights reserved.