
// Size of the array, ie. number of link1s to be randomly chosen.
var maxsize1 = 4;

// Image's width and height.
var width1 = 318;
var height1 = 117;

// Specify the link1s.
// Format: "URL,description,target,imageurl".
var link1 = new makeArray1(maxsize1);
link1[0] = new link1Obj("http://www.westpropower.com/generator.iml?id=4", "Portable Generator", "_top", "images/promos/Generator.jpg");
link1[1] = new link1Obj("http://www.westinghousesolar.com", "Westinghouse Solar", "_top", "images/promos/solar1.jpg");
link1[2] = new link1Obj("http://www.westinghouselighting.com", "It's your money, your lifestyle, your Westinghouse Lighting", "_top", "images/promos/light04.jpg");
link1[3] = new link1Obj("http://www.westinghousehvac.com/wh24srac.asp", "iQDrive", "_top", "images/promos/nordyne02.gif");
var n = 0;

function link1Obj(url, description, target, img) {
  this.url = url;
  this.description = description;
  this.target = (target != null) ? target : "_top";
  this.image = img;
  return this;
}

function gotoUrl1(x) {
  if (link1[x].target != null)
    window.open(link1[x].url, link1[x].target);
  else
    location.href = link1[x].url;
}

function makeArray1(size) {
  this.length = size;
  return this;
}

function showStatus1(x) {
  window.status = link1[x].description;
}

function getImageName1(x) {
  return link1[x].image;
}

while (1) {
  n = Math.round(Math.random() * 10);
  if (n >= 0 && n < maxsize1)
    break;
}

// HTML output

var banner2 = "<a href='javascript:gotoUrl1(" + n + ")'    OnMouseOver=\"MM_swapImage('learnmore1','','images/features_roll-over.gif',1);showStatus1(" + n + ");return true\" ";
banner2 += "OnMouseOut=\"MM_swapImage('learnmore1','','images/features_roll.gif',1);window.status=''\">";
banner2 += "<img border=0 width=" + width1 + " height=" + height1 + "name=\"bannerimg\" src=\"" + getImageName1(n) + "\"></a></td></tr><tr><td align=\"right\">";

var button2 = "<a href='javascript:gotoUrl1(" + n + ")' ";
button2 += "onMouseOut=\"MM_swapImgRestore()\" ";
button2 += "onMouseOver=\"MM_swapImage('learnmore1','','images/features_roll-over.gif',1); showStatus1(" + n + ");return true\">";
button2 +="<img src=\"images/features_roll.gif\" alt=\"Learn More\" name=\"learnmore1\" width=\"141\" height=\"16\" border=\"0\"></a> ";


document.write(banner2);
document.write(button2);



