|Time | IF | Date Object | Arrays | Avoid the work | Hide email | Random | Intigrate HTML | Test|
This will not be a place to get all the latest cut and paste scripts. There are lots of places on the web for that. Try Dynamic Drive
This is merely intended to take the mystery out of the subject.
For instance :
This is a part of what I wrote.
We already knew what time it was before we entered the page.
Understanding the time object and using it to keep your text current is only one of the much more practical ways to use it.
Probably no longer needed but just put it in and forget it is there.
This is done with 'document.write( )' ( Even easy to remember the name )
Pulling it apart we see that document.write ( ) will print whatever is between the brackets that always follow it ( )
What it writes must be in parentheses (either double " " or single ' ' but they must match )unless it is printing a variable which we come to next.
To review this is how the previous script will look in its entirity.
An important note about parentheses :
This makes it possible to put the opposite parentheses within the text like this.
Next : Time