﻿function initImgRotation() 
{
  // create rotating image objects here 
  // arguments: image name, rotation speed (milliseconds)
  var rotator1 = new rotateImgObj('img_logopartners',3902);
  rotator1.addImages('100.jpg','1004.jpg','101.jpg','1011.gif','102.jpg','1030.jpg','1035.gif','104.jpg','1051.gif','1057.jpg','107.jpg','1070.jpg','1080.gif','1095.gif','1100.gif','1101.gif','1108.gif','111.jpg','1117.gif','1125.gif','1127.gif','1128.gif','1129.gif','113.gif','1130.jpg','1138.gif','1139.gif','1145.jpg','1146.gif','1147.jpg','116.gif','1180.gif','1189.gif','1195.jpg','1197.jpg','1208.gif','1209.jpg','1210.jpg','1211.gif','1217.gif','122.jpg','1241.jpg','1242.jpg','1258.gif','1281.gif','1294.jpg','1295.gif','1315.gif','132.gif','133.gif','134.gif','135.gif','137.gif','138.jpg','141.gif','142.gif','144.jpg','145.gif','146.jpg','148.gif','1483.gif','149.jpg','150.jpg','151.gif','153.gif','155.gif','1554.gif','156.gif','158.jpg','159.gif','160.gif','164.gif','166.gif','167.jpg','168.gif','169.gif','172.gif','175.gif','178.gif','1782.gif','179.jpg','180.gif','181.jpg','184.gif','185.gif','186.gif','1884.gif','189.gif','190.jpg','192.jpg','193.gif','1933.gif','197.gif','203.gif','210.gif','211.gif','214.gif','215.jpg','216.gif','2160.jpg','2187.gif','220.gif','221.jpg','225.jpg','226.gif','229.gif','230.gif','232.gif','235.gif','237.gif','2510.jpg','2521.gif','257.jpg','258.jpg','259.jpg','2608.gif','261.gif','263.gif','2637.gif','266.gif','269.gif','270.jpg','2721.gif','274.gif','281.gif','283.gif','286.jpg','2875.jpg','288.gif','298.gif','299.gif','307.gif','310.jpg','311.gif','312.gif','313.gif','318.gif','3270.gif','328.gif','333.jpg','334.gif','337.gif','339.gif','340.gif','342.jpg','344.jpg','347.gif','350.gif','351.jpg','355.gif','357.gif','358.gif','361.gif','362.gif','364.gif','370.gif','381.gif','3869.gif','391.jpg','392.gif','3975.jpg','4067.gif','4270.gif','4556.jpg','4977.gif','5031.gif','5090.gif','5184.jpg','5630.gif','5717.gif','5722.gif','5781.gif','5787.jpg','5788.gif','5996.jpg','6095.gif','6264.gif','6424.gif','6558.gif','6582.gif','6691.gif','7224.gif','7328.gif','735.gif','7370.gif','779.jpg','789.gif','793.gif','796.gif','806.gif','819.gif','853.jpg','861.gif','863.jpg','867.gif','874.gif','883.jpg','884.gif','890.gif','895.jpg','928.gif','93.jpg','94.jpg','941.gif','95.jpg','97.gif','976.jpg','992.jpg','996.jpg');  // add the images to rotate into that image object
  rotator1.addActions('http://www.fabory.nl/','http://www.simondehaas.nl/','http://www.fagerhult.nl/','http://www.stelrad.com/','http://www.havells-sylvania.com/','http://www.trilux.nl','http://www.meerakker.nl/','http://www.hkelectric.nl/','http://www.verholt.nl/','http://www.walravenbv.com/','http://www.goudaholland.nl/','http://www.duscholux.nl/','http://www.agp.nl','http://www.pil-nl.com/','http://www.jaga.be/','http://www.bvlicht.nl/','http://www.derijk.nl/','http://www.holec.nl/','http://www.vedotec.nl/','http://www.walraven.com/','http://www.exact.nl/','http://www.allinco.nl/','http://www.spirair.nl/','http://www.schneiderelectric.nl/','http://www.bus.nl/','http://www.berner.nl/','http://www.honeywell.nl/','http://www.deleidinggroothandel.nl','http://www.saniceve.nl/','http://www.vugt.nl','http://www.weidmuller.nl/','http://www.comari.com','http://www.finder.nl/','http://www.tttbv.nl/','http://www.cablepartners.nl/','http://www.eszet.nl/','http://www.eszet.nl/','http://www.eszet.nl/','http://www.breur.nl','http://www.burgerhout.nl/','http://www.jacs-koopman.nl/','http://www.heimeier.com/','http://www.herz-armaturen.com/','http://www.kleventa.nl/','http://www.wiringa.nl/','#','#','http://www.engros.nl/','http://www.vihamij.nl/','http://www.conelgro.nl/','http://www.vanegmond.nl/','http://www.phoenixcontact.nl/','http://www.elauma.nl/','http://www.eupen.com/','http://www.biral.nl/','http://www.technischeunie.com/','http://www.solarnederland.nl/','http://www.hagemeyer.nl/','http://www.hemmink.nl/','http://www.eselektro.nl/','http://www.airco-verwarming.nl/','http://www.waagmeester.nl/','http://www.nexans.nl/','http://www.bliekelektrotechniek.nl/','http://www.pipelife.nl/','http://www.philips.com/','http://www.aircovent.nl/','http://www.rexel.com/','http://www.odsbv.nl/','http://www.legrandnederland.nl/','http://www.maskate.nl/','http://www.abb.nl/','http://www.kannegieter.nl/','http://www.schuurman.nl/','http://www.oosterberg.nl/','http://www.proplanet.nl/','http://www.frige.nl/','http://www.dyka.com/','http://www.drakakabel.nl/','http://www.belimo.nl/','http://www.galvano.nl/','http://www.steenkist.nl/','http://www.flamco.nl/','http://www.luttershandel.nl/','http://www.macbright.com/','http://www.klemko.nl/','http://www.bonfix.nl/','http://www.waterloo.nl/','http://www.merfordgroup.nl/','http://www.wasco.nl/','http://www.4ps.nl/','http://www.caleffi.nl/','http://www.cablemasters.nl/','http://www.barcol-air.nl/','http://www.plieger.nl/','http://www.aras.nl/','http://www.bailey.nl/','http://www.batterijimport.nl/','http://www.biddle.nl/','http://www.durinck.nl/','http://www.ecr-nederland.nl','http://www.tourandersson.com/','http://www.nedelko.nl','http://www.schilt-meerkerk.nl/','http://www.dales.nl/','http://www.velu.nl/','http://www.solid-air.nl/','http://www.grundfos.nl/','http://www.krausnaimer.com/','http://www.overtoom.nl/','http://www.hatenboer.com/','http://www.hbi-noodverlichting.nl','http://www.gevier.nl/','http://www.rensa.nl/','http://www.geberit.nl/','http://www.heg.nl/','http://www.econosto.nl/','http://www.pilz.nl/','http://www.ibmo.eu','http://www.gafco-altron.nl/','http://www.donne.nl/','http://www.jestorkair.nl/','http://www.inventum.nl/','http://www.soler-palau.nl','http://www.rehau.nl/','http://www.thermonoord.nl/','http://www.tycobuilding.com/','http://www.kwx.nl/','http://www.lasaulec.nl/','http://www.compricon.nl/','http://www.coolmark.nl/','http://www.dtcelektro.nl/','http://www.hokamo.nl/','http://www.haring.nl/','http://www.sphinx.nl/','http://www.obo-bettermann.nl/','http://www.ihb.nl/','http://www.priva.nl/','http://www.vegro.nl/','http://www.adi-gardiner.nl','http://www.enk.nl/','http://www.e-light.nl/','http://www.syntess.nl/','http://www.snoeck-eg.nl/','#','http://www.tkmn.nl/','http://www.installogic.nl/','http://www.bouwinfosys.nl/','http://www.uneto-vni.nl/','http://www.forehand.nl/','http://www.etk.nl/','http://www.televersal.com','http://www.maaslandgroep.nl/','http://www.vercoma.nl/','http://www.elbotechnology.nl/','http://www.dgc-inkoop.nl/','http://www.exact.nl/','http://www.voltec.nl/','http://www.eppinkelektro.nl/','http://www.vredenburg.net/','http://www.theben.de/','http://www.kobout.nl/','http://www.siemens.nl/','http://www.hsombs.com/','http://www.inox.nl','http://www.van-buuren.com/','http://www.king.nl','http://www.elsinghorst.nl','http://www.redlink.nl','http://www.norbain-benelux.com','http://www.elektrocafe.nl','http://www.burlight-design.nl/','http://www.newminds.nl','http://www.elektrowestland.nl','http://www.xserius.nl','http://www.vtgrijswijk.nl','http://www.sdclogistics.nl/','http://www.gerritse.nl','http://www.mamut.nl','http://www.osec.nl','http://www.ifb-filtertechniek.nl','http://www.interlandtechniek.nl','http://www.disselbv.nl','http://www.admicom.nl/','http://www.ilocal.nl/nl/centrale-verwarming/cevetech/728708578248654','http://www.airtradecentre.com/','http://www.attiva.nl/','http://www.belpa.nl/','http://www.biesheuvelgroep.nl/','http://www.centercon.nl','http://www.danfossverwarming.nl/','http://www.texit-benelux.nl/','http://www.gea-happel.nl/','http://www.geurts-janssenhabraken.nl/','http://www.gibaco.nl/','http://www.hadeg.nl/','http://www.henrad.com/','http://www.hibro.nl/','http://www.hooglandmennens.nl','http://www.inatherm.nl/','http://www.ksb.nl/','http://www.wavin.nl/','http://www.eldon.nl/','http://www.dumoulin.nl/','http://www.peha-elektro.nl/','http://www.rittal.nl/','http://www.pmkomponenten.nl/','http://www.salo.nl/','http://www.schonkerenbv.nl/'); // add the corresponding actions to take onclick of those images destination url or function pointer
  rotator1.rotate();
  
  var rotator2 = new rotateImgObj('img_aandeelhouders',6051);
  rotator2.addImages('100.jpg','1004.jpg','101.jpg','1011.gif','102.jpg','1030.jpg','1035.gif','104.jpg','1051.gif','1057.jpg','107.jpg','1070.jpg','1080.gif','1095.gif','1100.gif','1101.gif','1108.gif','111.jpg','1117.gif','1125.gif','1127.gif','1128.gif','1129.gif','113.gif','1130.jpg','1138.gif','1139.gif','1145.jpg','1146.gif','1147.jpg','116.gif','1180.gif','1189.gif','1195.jpg','1197.jpg','1208.gif','1209.jpg','1210.jpg','1211.gif','1217.gif','122.jpg','1241.jpg','1242.jpg','1258.gif','1281.gif','1294.jpg','1295.gif','1315.gif','132.gif','133.gif','134.gif','135.gif','137.gif','138.jpg','141.gif','142.gif','144.jpg','145.gif','146.jpg','148.gif','1483.gif','149.jpg','150.jpg','151.gif','153.gif','155.gif','1554.gif','156.gif','158.jpg','159.gif','160.gif','164.gif','166.gif','167.jpg','168.gif','169.gif','172.gif','175.gif','178.gif','1782.gif','179.jpg','180.gif','181.jpg','184.gif','185.gif','186.gif','1884.gif','189.gif','190.jpg','192.jpg','193.gif','1933.gif','197.gif','203.gif','210.gif','211.gif','214.gif','215.jpg','216.gif','2160.jpg','2187.gif','220.gif','221.jpg','225.jpg','226.gif','229.gif','230.gif','232.gif','235.gif','237.gif','2510.jpg','2521.gif','257.jpg','258.jpg','259.jpg','2608.gif','261.gif','263.gif','2637.gif','266.gif','269.gif','270.jpg','2721.gif','274.gif','281.gif','283.gif','286.jpg','2875.jpg','288.gif','298.gif','299.gif','307.gif','310.jpg','311.gif','312.gif','313.gif','318.gif','3270.gif','328.gif','333.jpg','334.gif','337.gif','339.gif','340.gif','342.jpg','344.jpg','347.gif','350.gif','351.jpg','355.gif','357.gif','358.gif','361.gif','362.gif','364.gif','370.gif','381.gif','3869.gif','391.jpg','392.gif','3975.jpg','4067.gif','4270.gif','4556.jpg','4977.gif','5031.gif','5090.gif','5184.jpg','5630.gif','5717.gif','5722.gif','5781.gif','5787.jpg','5788.gif','5996.jpg','6095.gif','6264.gif','6424.gif','6558.gif','6582.gif','6691.gif','7224.gif','7328.gif','735.gif','7370.gif','779.jpg','789.gif','793.gif','796.gif','806.gif','819.gif','853.jpg','861.gif','863.jpg','867.gif','874.gif','883.jpg','884.gif','890.gif','895.jpg','928.gif','93.jpg','94.jpg','941.gif','95.jpg','97.gif','976.jpg','992.jpg','996.jpg');
  rotator2.addActions('http://www.fabory.nl/','http://www.simondehaas.nl/','http://www.fagerhult.nl/','http://www.stelrad.com/','http://www.havells-sylvania.com/','http://www.trilux.nl','http://www.meerakker.nl/','http://www.hkelectric.nl/','http://www.verholt.nl/','http://www.walravenbv.com/','http://www.goudaholland.nl/','http://www.duscholux.nl/','http://www.agp.nl','http://www.pil-nl.com/','http://www.jaga.be/','http://www.bvlicht.nl/','http://www.derijk.nl/','http://www.holec.nl/','http://www.vedotec.nl/','http://www.walraven.com/','http://www.exact.nl/','http://www.allinco.nl/','http://www.spirair.nl/','http://www.schneiderelectric.nl/','http://www.bus.nl/','http://www.berner.nl/','http://www.honeywell.nl/','http://www.deleidinggroothandel.nl','http://www.saniceve.nl/','http://www.vugt.nl','http://www.weidmuller.nl/','http://www.comari.com','http://www.finder.nl/','http://www.tttbv.nl/','http://www.cablepartners.nl/','http://www.eszet.nl/','http://www.eszet.nl/','http://www.eszet.nl/','http://www.breur.nl','http://www.burgerhout.nl/','http://www.jacs-koopman.nl/','http://www.heimeier.com/','http://www.herz-armaturen.com/','http://www.kleventa.nl/','http://www.wiringa.nl/','#','#','http://www.engros.nl/','http://www.vihamij.nl/','http://www.conelgro.nl/','http://www.vanegmond.nl/','http://www.phoenixcontact.nl/','http://www.elauma.nl/','http://www.eupen.com/','http://www.biral.nl/','http://www.technischeunie.com/','http://www.solarnederland.nl/','http://www.hagemeyer.nl/','http://www.hemmink.nl/','http://www.eselektro.nl/','http://www.airco-verwarming.nl/','http://www.waagmeester.nl/','http://www.nexans.nl/','http://www.bliekelektrotechniek.nl/','http://www.pipelife.nl/','http://www.philips.com/','http://www.aircovent.nl/','http://www.rexel.com/','http://www.odsbv.nl/','http://www.legrandnederland.nl/','http://www.maskate.nl/','http://www.abb.nl/','http://www.kannegieter.nl/','http://www.schuurman.nl/','http://www.oosterberg.nl/','http://www.proplanet.nl/','http://www.frige.nl/','http://www.dyka.com/','http://www.drakakabel.nl/','http://www.belimo.nl/','http://www.galvano.nl/','http://www.steenkist.nl/','http://www.flamco.nl/','http://www.luttershandel.nl/','http://www.macbright.com/','http://www.klemko.nl/','http://www.bonfix.nl/','http://www.waterloo.nl/','http://www.merfordgroup.nl/','http://www.wasco.nl/','http://www.4ps.nl/','http://www.caleffi.nl/','http://www.cablemasters.nl/','http://www.barcol-air.nl/','http://www.plieger.nl/','http://www.aras.nl/','http://www.bailey.nl/','http://www.batterijimport.nl/','http://www.biddle.nl/','http://www.durinck.nl/','http://www.ecr-nederland.nl','http://www.tourandersson.com/','http://www.nedelko.nl','http://www.schilt-meerkerk.nl/','http://www.dales.nl/','http://www.velu.nl/','http://www.solid-air.nl/','http://www.grundfos.nl/','http://www.krausnaimer.com/','http://www.overtoom.nl/','http://www.hatenboer.com/','http://www.hbi-noodverlichting.nl','http://www.gevier.nl/','http://www.rensa.nl/','http://www.geberit.nl/','http://www.heg.nl/','http://www.econosto.nl/','http://www.pilz.nl/','http://www.ibmo.eu','http://www.gafco-altron.nl/','http://www.donne.nl/','http://www.jestorkair.nl/','http://www.inventum.nl/','http://www.soler-palau.nl','http://www.rehau.nl/','http://www.thermonoord.nl/','http://www.tycobuilding.com/','http://www.kwx.nl/','http://www.lasaulec.nl/','http://www.compricon.nl/','http://www.coolmark.nl/','http://www.dtcelektro.nl/','http://www.hokamo.nl/','http://www.haring.nl/','http://www.sphinx.nl/','http://www.obo-bettermann.nl/','http://www.ihb.nl/','http://www.priva.nl/','http://www.vegro.nl/','http://www.adi-gardiner.nl','http://www.enk.nl/','http://www.e-light.nl/','http://www.syntess.nl/','http://www.snoeck-eg.nl/','#','http://www.tkmn.nl/','http://www.installogic.nl/','http://www.bouwinfosys.nl/','http://www.uneto-vni.nl/','http://www.forehand.nl/','http://www.etk.nl/','http://www.televersal.com','http://www.maaslandgroep.nl/','http://www.vercoma.nl/','http://www.elbotechnology.nl/','http://www.dgc-inkoop.nl/','http://www.exact.nl/','http://www.voltec.nl/','http://www.eppinkelektro.nl/','http://www.vredenburg.net/','http://www.theben.de/','http://www.kobout.nl/','http://www.siemens.nl/','http://www.hsombs.com/','http://www.inox.nl','http://www.van-buuren.com/','http://www.king.nl','http://www.elsinghorst.nl','http://www.redlink.nl','http://www.norbain-benelux.com','http://www.elektrocafe.nl','http://www.burlight-design.nl/','http://www.newminds.nl','http://www.elektrowestland.nl','http://www.xserius.nl','http://www.vtgrijswijk.nl','http://www.sdclogistics.nl/','http://www.gerritse.nl','http://www.mamut.nl','http://www.osec.nl','http://www.ifb-filtertechniek.nl','http://www.interlandtechniek.nl','http://www.disselbv.nl','http://www.admicom.nl/','http://www.ilocal.nl/nl/centrale-verwarming/cevetech/728708578248654','http://www.airtradecentre.com/','http://www.attiva.nl/','http://www.belpa.nl/','http://www.biesheuvelgroep.nl/','http://www.centercon.nl','http://www.danfossverwarming.nl/','http://www.texit-benelux.nl/','http://www.gea-happel.nl/','http://www.geurts-janssenhabraken.nl/','http://www.gibaco.nl/','http://www.hadeg.nl/','http://www.henrad.com/','http://www.hibro.nl/','http://www.hooglandmennens.nl','http://www.inatherm.nl/','http://www.ksb.nl/','http://www.wavin.nl/','http://www.eldon.nl/','http://www.dumoulin.nl/','http://www.peha-elektro.nl/','http://www.rittal.nl/','http://www.pmkomponenten.nl/','http://www.salo.nl/','http://www.schonkerenbv.nl/');
  rotator2.rotate();
  
  rotateImgObj.start();
}
// If all the images you wish to display are in the same location, you can specify the path here 
rotateImgObj.imagesPath = "crl/logos/banners/";
// if you want url's to open in a separate window, un-comment this line
//rotateImgObj.tgt = "_blank"; 

// no need to edit code below 
/////////////////////////////////////////////////////////////////////
rotateImgObjs = []; // holds all rotating image objects defined
// constructor 
function rotateImgObj(nm,s) {
  this.speed=s; this.ctr=0; this.timer=0;  
  this.imgObj = document.images[nm]; // get reference to the image object
  this.index = rotateImgObjs.length; rotateImgObjs[this.index] = this;
  this.animString = "rotateImgObjs[" + this.index + "]";
}

rotateImgObj.prototype = {
  addImages: function() { // preloads images
  if (this.imgObj != null)
  {
    this.imgObj.imgs = [];
    for (var i=0; i<arguments.length; i++) {
      //this.imgObj.imgs[i] = new Image();
      this.imgObj.imgs[i] = rotateImgObj.imagesPath + arguments[i];
    }
    }
  },
  
  addActions: function() {
    this.actions = [];
    for (var i=0; i<arguments.length; i++) { this.actions[i] = arguments[i]; }
  },
  
  rotate: function() {
    if (this.imgObj != null)
  {
    this.ctr = Math.round((this.imgObj.imgs.length-1)*Math.random());
    this.imgObj.src = this.imgObj.imgs[this.ctr]
    }
  }
}

// sets up rotation for all defined rotateImgObjs
rotateImgObj.start = function() {
  for (var i=0; i<rotateImgObjs.length; i++) 
    rotateImgObjs[i].timer = setInterval(rotateImgObjs[i].animString + ".rotate()", rotateImgObjs[i].speed);                     
}

// called onclick of images
rotateImgObj.doClick = function(n) {
	if ( document.images && rotateImgObjs[n] ) {
    var obj = rotateImgObjs[n]; // shorten reference 
    if ( obj.actions && obj.actions[obj.ctr] ) {
  		if ( typeof obj.actions[obj.ctr] == "string" ) {
        if ( rotateImgObj.tgt == "_blank" ) {
          // open in separate window (add features here if you want, i.e., chrome, size, position, ...)
          var win = window.open(obj.actions[obj.ctr], "subwin");
          if ( win && !win.closed ) win.focus();
        } else window.location = obj.actions[obj.ctr];
      } else obj.actions[obj.ctr]();
    } 
    return false;
	} else return true;
}

// for stopping/starting onmouseover/out
rotateImgObj.pause = function(n) {	
  if (rotateImgObjs[n]) clearInterval(rotateImgObjs[n].timer); 
}

rotateImgObj.resume = function(n) {
  if ( rotateImgObjs[n] ) {
    var obj = rotateImgObjs[n]; // shorten reference 
    obj.rotate(); // rotate now and resume repeated calls
    obj.timer = setInterval( obj.animString + ".rotate()", obj.speed );
  }
}