Recall that
the src attribute is responsible for providing the actual filename of the graphic to be displayed; it is, quite
literally, the source of the image. A rollover changes the value of src from one image file to another.
Swapping the src value is analogous to having a picture within a frame and changing the picture while
keeping the frame.
The picture frame analogy is appropriate on one other level: It serves as a reminder of the
size barrier inherent in rollovers. A rollover changes only one property of an
![]()
tag, the
source??”it cannot change any other property, such as height or width. For this reason, both your original
image and the image displayed during the rollover should be the same size. If they are not, the alternate
image is resized to match the dimensions of the original image.
Dreamweaver??™s Rollover Image object automatically changes the image back to its original source when the
user moves the pointer off the image. Optionally, you can elect to preload the images with the selection of a
checkbox. Preloading is a Web page technique that reads the intended file or files into the browser??™s memory
before they are displayed. With preloading, the images appear on demand, without any download delay.
Rollovers are typically used for buttons that, when clicked, open another Web page.
Pages:
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680