function checkBrowser(){
this.ver=navigator.appVersion
this.dom=document.getElementById?1:0
this.ie5=(this.ver.indexOf("MSIE 5")>-1 && this.dom)?1:0;
this.ie4=(document.all && !this.dom)?1:0;
this.ns5=(this.dom && parseInt(this.ver) >= 5) ?1:0;
this.ns4=(document.layers && !this.dom)?1:0;
this.bw=(this.ie5 || this.ie4 || this.ns4 || this.ns5)
return this
}
function openC550Flash(site) {
  subwin = window.open(site, 'popup', 'width=525,height=400,left=0,top=0,scrollbars=no,status=yes,toolbar=no')
  subwin.focus();
}

function openFlash(site) {
  subwin = window.open(site, 'popup', 'width=400,height=300,left=0,top=0,scrollbars=no,status=yes,toolbar=no')
  subwin.focus();
}

function openFlashLg(site) {
  subwin = window.open(site, 'popup', 'width=820,height=620,left=0,top=0,scrollbars=no,status=yes,toolbar=no')
  subwin.focus();
}
function openAnnouncement(site) {
  subwin = window.open(site, 'popup', 'width=525,height=450,left=0,top=0,scrollbars=no,status=yes,toolbar=no')
  subwin.focus();
}

function openWideFlash(site) {
  subwin = window.open(site, 'popup', 'width=665,height=450,left=0,top=0,scrollbars=no,status=yes,toolbar=no')
  subwin.focus();
}
function lgimg(URL){
bCheck = new checkBrowser();
var Xpos = (window.screen.availWidth-636)/2;
var Ypos = (window.screen.availHeight-500)/2;
var Features = 'width=636,height=500,resizable,scrollbars=1';
if (bCheck.ie5||bCheck.ie4){Features = Features + ',left='+Xpos+',top='+Ypos;}
if (bCheck.ns5||bCheck.ns4){Features = Features + ',screenX='+Xpos+',screenY='+Ypos;}
var CtrWin = window.open(URL,'SubWin',Features);
}

var theImages = new Array();
var theImagesAlt = new Array();
var theImagesURL = new Array();
var theImagesTarget = new Array();

theImages[0] = '/img/products/green_at_heart_1.gif';
theImages[1] = '/img/products/vertical_150x73.jpg';
theImages[2] = '/img/products/green_at_heart_1.gif';
theImages[3] = '/img/products/vertical_150x73.jpg';

theImagesAlt[0] = 'Green at Heart';
theImagesAlt[1] = 'Vertical Markets';
theImagesAlt[2] = 'Green at Heart';
theImagesAlt[3] = 'Vertical Markets';

theImagesURL[0] = 'http://kmbs.konicaminolta.us/content/environment/environment.html';
theImagesURL[1] = 'http://kmbs.konicaminolta.us/vertical/index.html';
theImagesURL[2] = 'http://kmbs.konicaminolta.us/content/environment/environment.html';
theImagesURL[3] = 'http://kmbs.konicaminolta.us/vertical/index.html';

theImagesTarget[0] = '_self';
theImagesTarget[1] = '_blank';
theImagesTarget[2] = '_self';
theImagesTarget[3] = '_blank';

var j = 0
var p = theImages.length;
var preBuffer = new Array()
for (i = 0; i < p; i++){
   preBuffer[i] = new Image()
   preBuffer[i].src = theImages[i]
}
var whichImage = Math.round(Math.random()*(p-1));
function showImage(){
document.write('<a href="' + theImagesURL[whichImage] + '" target="' + theImagesTarget[whichImage] + '"><img src="'+theImages[whichImage]+'" alt="' + theImagesAlt[whichImage] + '" width="150" height="73" class="ads"></a>');
}
