Date and Time

There are a lot of options for showing the current time and date on a page. The code on this page updates automatically when the page loads, and should show the "local" time (your computer's time). Here is a page from w3schools that gives you some great lists; don't let it frighten you. When you begin learning JavaScript, it will make more sense!

 

arrow pointing left  A Calculator

The JavaScript code for this calculator has some familiar tags in it from when we learned about tables, and also uses the <form> tag. It has been modified from the original. Unfortunately, the code doesn't include the decimal point! You can see why being able to create JavaScript from scratch could help you "fix" things like this.

The original code was found here, at Code Toad.


Pop-ups

While they can be annoying, pop-ups can also be a good way to provide tidbits of information. One caution about using these: remember that some people have pop-up blockers and may want to skip it.

There are different ways of doing this, including the two linked below (the baseball one includes an "alert box"). Check Tizag for a good tutorial.


Scripts from other sites

Make sure you include all comments and information when using scripts offered at another site. The cat age calculator here is just one example of the fun things out there!