TechiWarehouse.Com


Top 3 Products & Services

1.
2.
3.

Dated: Sep. 11, 2005

Related Categories

DHTML (Dynamic HTML)

By Najmi

Standard HTML is a combination of different elements, or tags, which are designed to hold data in a certain fashion. Dynamic HTML extends these tags by making "objects" of them, and allowing you to alter the way the data is presented by altering those tag "objects." JavaScript does much the same thing, and is itself used in DHTML to control these tags. Examples of JavaScript objects include window, frame, history, navigator, document, etc. Examples of DHTML objects include head, title, bgcolor, forecolor, src,

Animation Techniques in DHTML

setTimeout, setInterval, clearTimeout, clearInterval

These four methods are all window methods, and provide a solid backbone for most animation techniques in DHTML.

They can also be grouped as:

setTimeout, clearTimeout

and

setInterval, clearInterval

Animation Techniques in DHTMLThese two pairs are very similar, but there is one significant difference. With both pairs, we tell the script to call a specified function after a specified amount of time. With Timeout, this only occurs once, with Interval this occurs periodically.

Obviously, we may only wish a function to be called periodically for a while, and then we wish to do something else, and we use the clearInterval method to stop any programmed setInterval methods.

setTimeout is often used for animating objects - we could use setInterval, but setInterval is less easy to control.

  Page 1 of 7
  First | Previous | Next | Last

Now that you've gotten free know-how on this topic, try to grow your skills even faster with online video training. Then finally, put these skills to the test and make a name for yourself by offering these skills to others by becoming a freelancer. There are literally 2000+ new projects that are posted every single freakin' day, no lie!


Previous Article

Next Article