// JS to handle images for the various created-by-ewc logo states.
// It caches the images and provides a function to switch between them.
//
// Copyright 1999, Mark Callow, www.edgewise-consulting.com.
// All rights reserved.

// I have noticed a problem (race?) in Netscape 4 where sometimes
// document.images is null at time this code is executed. One
// solution is to delay the cacheing until the document is loaded
// by placing this in an onLoad function. This has ugly ramifications
// for use of this logo in general web pages. For now we leave it as
// is and see of the problem crops up in real use.
//
// The test for document.images is to prevent failures in older browsers
// where images are not available as JS objects.

if (document.images) {
  var Nby_ewc_up = new Image(88,41);
  Nby_ewc_up.src = "http://www.edgewise-consulting.com/created/by_ewc_up.gif";

  var Nby_ewc_over = new Image(88,41);
  Nby_ewc_over.src = "http://www.edgewise-consulting.com/created/by_ewc_over.gif";

  var Nby_ewc_down = new Image(88,41);
  Nby_ewc_down.src = "http://www.edgewise-consulting.com/created/by_ewc_down.gif";
}

function ewc_di(id,state) {
  if (document.images) document.images[id].src=eval(id+'_'+state+".src");
}

