home *** CD-ROM | disk | FTP | other *** search
/ DOS/V Power Report 2000 December / VPR0012A.BIN / POWERDVD / HTML / jpn / image / imagech.js < prev    next >
Text File  |  2000-02-14  |  494b  |  25 lines

  1. if (document.images) {
  2. }
  3.  
  4. function di20(id, newSrc) {
  5.  var theImage = FWFindImage(document, id, 0);
  6.  if (theImage)
  7.   theImage.src = newSrc;
  8. }
  9.  
  10. function FWFindImage(doc, name, j) {
  11.  var theImage = false;
  12.  if (doc.images)
  13.   theImage = doc.images[name];
  14.  if (theImage)
  15.   return theImage;
  16.  if (doc.layers) {
  17.   for (j = 0; j < doc.layers.length; j++) {
  18.    theImage = FWFindImage(doc.layers[j].document, name, 0);
  19.    if (theImage)
  20.     return theImage;
  21.   }
  22.  }
  23.  return false;
  24. }
  25.