Saturday, January 31, 2009

Javascript Introduction

JavaScript, a programming language built into your web browser, is one
of the best ways to add interactivity to your website because it’s the only crossbrowser language that works directly with web browsers. Other languages
such as Java, Perl, PHP, and C don’t have direct access to the images, forms,
and windows that make up a web page.

JavaScript is also very easy to learn. You don’t need any special hardware
or software, you don’t need access to a webserver, and you don’t need a degree
in computer science to get things working. All you need is a web browser and
a text editor such as SimpleText or Notepad.

There are severways to find out a bug in your browser:

If you are a Mozilla user you can trace you JavaScript errors as following

From your browser Toos -> Error Console.

Here we are shown with all the errors mage by us.

There are different Addons available in Mozilla Firefox browser to trace the javascript error

Suggestable Addons are:

Firebug :
Which i prefer the most usefull in tracing errors.Firebug integrates with Firefox to put a wealth of development tools at your fingertips while you browse. You can edit, debug, and monitor CSS, HTML, and JavaScript live in any web page... Firebug 1.3 requires Firefox 2 or 3.

Obtrusive JavaScript Checker : Finds HTML elements with inline events and javascript: links

JavaScript Options : Provides advanced JavaScript options for Firefox.

Inline Code Finder for Firebug : Inline Code Finder is an add-on to Firebug, to be able to find HTML elements with any of the below issues: * Inline JavaScript events * Inline style * javascript: links Detailed description can be found at http://www.robertnyman.com/inline-code-finder/