JavaScript Mr Trofimczuk
JavaScript Lessons (6 lessons until Christmas break=12hrs)


What is JavaScript?
JavaScript is THE scripting language of the Web. JavaScript is used in billions of Web pages to add functionality, validate forms, communicate with the server, and much more.

What Do I Need to Run JavaScript?:

JavaScript support is built right into all the major web browsers, including Internet Explorer, Firefox and Safari. Provided that the visitors to your site are using web browsers that support JavaScript (most do) and have JavaScript enabled (it is by default), then your JavaScript will run when they visit the page.

Do I Need to Learn Javascript to Be Able to Use It?:

No. There are plenty of pre-written JavaScripts that people have made available for you to plug straight into your web page. All you need to know to be able to use such scripts is how to paste the supplied code into the required places in your web page.

What Do I Need to Write JavaScript?:

JavaScript is an interpreted language, so no special program is required to create usable code. Any plain text editor such as Notepad (one of the Accessories that comes in Windows) is quite satisfactory for being able to write JavaScript. That said, an editor that colorizes the code to make it easier to see what is what makes it easier to find your mistakes.

Can I Use HTML Instead of JavaScript?:
No. HTML and JavaScript are two completely different things. HTML is a markup language designed for defining static web page content. JavaScript is a programming language designed for performing dynamic tasks. Sometimes the distinction is confusing because JavaScript code can go in the same file as HTML.

Does the Javascript Go in the Same File as the HTML?:

It can, but your scripts will be more easily reused on multiple pages of your site if you place them in separate files. (Using a .JS extension helps identify them as Javascript.) You then just link the JavaScript to your HTML by inserting a <script> tag. The same JavaScript can then be added to several pages just by adding the appropriate tag into each of the pages to set up the link.