Menu

JavaScript

Introduction to JavaScript

Javascript can turn basic sites into highly ‘responsive’ interactive sites. Usually we reserve the word ‘responsive’ for CSS because it means the page responds different windows and environments. Javascript can be programmed to react to different environments, it’s main use is for its scripting ability. You may have heard of the programming language Java, and thought it must be related to JavaScript. JavaScript is quite different from Java and was only named similarly to Java [to try and pick up adoption of the language on the web.] Here are the [major differences] between Java and JavaScript. Still, JavaScript has wide uses and has many different ‘libraries,’ or add-ons including JQuerry which you can try out on W3Schools. JavaScript is also used in Ajax which allows for new content/data to be exchanged on a page without having to reload the entire page like PHP would have to. You may be a CSS pro and know that with some tricks you make content move, animate, or appear/disappear with only CSS. Although this shows CSS’ strengths as a language, all of the data that you are changing is loaded all at once onto the user’s browser. Think of the upside-down tree example on the CSS page. The water can do all sorts of things to the appearance of the tree, even making branches invisible (magical water! This can be done with {display: none}; and some sort of condition). What the water cannot do is cut of a branch or seemingly make a new branch. JavaScript, especially with Ajax technologies (Ajax is a group of technologies not one language), can send and fetch information from the hosting server depending on user input.

Let's Try It!

A great site to learn JavaScript and other languages is Codecademy which is completely free.

Make sure you select the 'JavaScript & CSS' under 'By Language' in the Catalogue. Then click 'JavaScript'. JavaScript needs CSS and when you want, go to the CSS page to get started.

Below is a JavaScript Playground, Where You Can Test Code!
W3Schools

Here are some videos that you can watch when you don't feel like coding.

(Who doesn't feel like coding right?) They cover the history of LANGUAGE and modern or unique uses.

The History of The Web

More on Markup Languages and JavaScript's Role

What Should I Learn to Actually Make a Nice, Functional Webpage?

It is important to note that all you need for a simple static website is JavaScript and CSS. A static website only gives information and cannot process any new information from the user. It is not fancy but can look nice

Learning Javascript can allow you to do fancy data management and PHP can automate webpage creation based on variable content