16. Basic Dynamic Techniques
Almost all of DHTML is based on a few basic tricks that allow you to hide or show elements, move them around, and make other changes. For the most part, these techniques are based on the ability to change the CSS properties of an element with JavaScript using the getElementbyId()
method to find it. However, you can also change the actual content between the tags of an object.
In this chapter, we’ll look at simple examples of how to create functions that change the following:
• An element’s visibility or display state to show and hide it
• An element’s position either to a specific location or by a certain amount.
• An element’s clipping region to show and hide parts of an element
• An element’s content after the page ...
Get CSS, DHTML, and Ajax: Visual QuickStart Guide, Fourth Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.