Script and DHTML Examples
The examples in this reference demonstrate how you can use scripts and Dynamic HTML (DHTML) to add functionality to your help system.
Script examples:
- Create a pop-up window by using JavaScript to call the TextPopup method. This example is intended to be used within a help topic, and is not the same feature as context-sensitive help, which opens in an external application. To implement context-sensitive help, you must work with the HTML Help API.
- Annotate an image by associating a series of pop-up windows with the regions of an image map. This example shows how you can annotate images in much the same way that Microsoft Help Workshop Hotspot Editor (Shed.exe) allows you to create and edit hypergraphics.
- Store text for pop-up windows in a text file instead of embedding the text in each HTML file. This example also shows how to link to the text file from an HTML file.
- Use JavaScript to create a secondary browser window that can be used to display text or graphics.
- Create a global script file to store all of your scripts in one easy-to-reference location. This can make it much easier to maintain scripts that affect multiple topics within a help system.
- Use JavaScript to link to a file outside of your help system. This is especially useful for linking to larger files, such as video clips.
DHTML examples:
- Use DHTML to create expandable sections that react to user input. This can help you to conserve screen space in your help topics.
- Create dynamic links that will liven up your help topics. This example shows the easiest way to add mouseover functionality to every hyperlink in your help project, and also shows how to create compact custom links using the <SPAN> tag.
Related topics