	  if ( typeof IS24_ODW == "undefined" ) {
	    var IS24_ODW = {};
	    
	    IS24_ODW.containerId = "odwNew";
	    IS24_ODW.rowNodeName = "tr";
	    IS24_ODW.cellNodeName = "div";
	    IS24_ODW.odwInterval = null;
	    IS24_ODW.placements = new Array();
	    IS24_ODW.numberOfSpecial = 0;
 	    IS24_ODW.numberOfPlacementsToShow = 4;
 	    IS24_ODW.numberOfPlacementsToScroll = 1;
 	    IS24_ODW.scrollToLeft = IS24_ODW.numberOfPlacementsToScroll > 0;
	  }
	  	    
	  function initPlacementsArray() {
	  	IS24_ODW.numberOfSpecial = 0;
	  	IS24_ODW.placements = new Array();
 	    
 	    // collect all tds an check wether they are placement cells
	  	var rawPlacements = document.getElementById(IS24_ODW.containerId).getElementsByTagName(IS24_ODW.cellNodeName);
	  	for(i = 0; i < rawPlacements.length; i++ ) {
	      if (isOdwCell(rawPlacements[i].id)) {
	        IS24_ODW.placements.push(rawPlacements[i]);
	        
	        if(isSpecialOdwCell(rawPlacements[i].id)) {
	        	IS24_ODW.numberOfSpecial++;
	        } // if
	      } // if
	    } // for
	    
	    // if we have more special cells than cells we can show we have some sort of problem:
	    // - special cells have to be shown every time
	    // - but we don't have enough slots to show all
	    // - during rotation non special cells would never be shown
	    //
	    // the solution:
	    // - remove all non special cells
	    // - make all special cells non special and keep on rotating
	    if(IS24_ODW.numberOfSpecial > IS24_ODW.numberOfPlacementsToShow) {
	    	var noSpecials = new Array();
	    	for(i = 0; i < IS24_ODW.placements.length; i++) {
	    		if(isSpecialOdwCell(IS24_ODW.placements[i].id)) {
	    			noSpecials.push(IS24_ODW.placements[i]);
	    		} else {
	    			var parentNode = IS24_ODW.placements[i].parent;
	    			if(parentNode) { 
	    				parentNode.removeChild(IS24_ODW.placements[i]);
	    			} // if
	    		} // else
	    	} // for
	    	
	    	IS24_ODW.placements = new Array();
	    	for(i = 0; i < noSpecials.length; i++) {
	    		var newId = specialOdwCellToNonSpecialOdwCell(noSpecials[i].id)
	    		IS24_ODW.placements.push(document.getElementById(newId));
	    		IS24_ODW.numberOfSpecial--;
	    	} // for
	    } // if
	  } // initPlacementsArray
	  
	  function scrollOdWs() {
	    if ( IS24_ODW.placements.length < IS24_ODW.numberOfPlacementsToShow || IS24_ODW.numberOfPlacementsToScroll == 0) {
	      // Dont scroll
	      return;
	    }
		
		// scroll our array internally, then  fix special placements (directly booked, the ymust be displayed)
		// finally refresh dom
		scrollArray();
		repairSpecialPlacements();
		refreshDom();
	  } // scrollOdws
	  
	  function scrollArray() {
	  	if(IS24_ODW.scrollToLeft) {
	  		for(i = 0; i < Math.abs(IS24_ODW.numberOfPlacementsToScroll); i++) {
	  			var removed = IS24_ODW.placements.shift();
	  			IS24_ODW.placements.push(removed);
	  		} // for
	  	} else {
	  		for(i = 0; i < Math.abs(IS24_ODW.numberOfPlacementsToScroll); i++) {
	  			var removed = IS24_ODW.placements.pop();
	  			IS24_ODW.placements.unshift(removed);
	  		} // for
	  	} // else
	  } // scrollArray
	  
	  function repairSpecialPlacements() {
	  	if(IS24_ODW.numberOfSpecial < 1) {
	  		return;
	  	} // if
	  	
	  	// all special placements must be displayed
	  	var placementsToFix = IS24_ODW.numberOfSpecial;
	  	for(var i = 0; i < IS24_ODW.placements.length && placementsToFix > 0; i++) {
	  		var curId = IS24_ODW.placements[i].id;
	  		if(isSpecialOdwCell(curId)) {
	  			// we have a special placement
	  			if(i >= IS24_ODW.numberOfPlacementsToShow) {
	  				// it is not visible so we have to fix it
		  			if(IS24_ODW.scrollToLeft) {
		  				// move pairwise backwards till its visible and all following special placements
		  				// will be visible too (placementsToFix-offset)
			  			var goBack = (i - IS24_ODW.numberOfPlacementsToShow) + placementsToFix;
			  			for(var j = 0; j < goBack; j++) {
			  				var goBackIndex = i - j;
			  				var temp = IS24_ODW.placements[goBackIndex - 1];
		  					IS24_ODW.placements[goBackIndex - 1] = IS24_ODW.placements[goBackIndex];
		  					IS24_ODW.placements[goBackIndex] = temp;
			  			} // for
			  		} else {
			  			// step 1
			  			// remove last placements till we have our special one to fix
			  			// this one has to be at pos 0
			  			var tempArray = new Array();
			  			var checkId = "";
			  			while(checkId != curId) {
			  				var removed = IS24_ODW.placements.pop();
			  				tempArray.unshift(removed);
			  				checkId = removed.id;
			  			} // while
			  			var hasToBeFirst = tempArray.shift();
			  			
			  			// put back all removed to the end
			  			for(var j = 0; j < tempArray.length; j++) {
			  				IS24_ODW.placements.push(tempArray[j]);
			  			} // for
			  			
			  			// step 2
			  			// remove all special ones at the beginning, cause they must stay there
			  			// otherwise they won't be visible anymore
			  			var shiftMore = true;
			  			tempArray = new Array();
			  			while(shiftMore) {
			  				var removed = IS24_ODW.placements.shift();
			  				if(isSpecialOdwCell(removed.id)) {
				  				// remember this one
				  				tempArray.unshift(removed);
			  				} else {
			  					// put is back, we don't have so save this
			  					IS24_ODW.placements.unshift(removed);
			  					shiftMore = false;
			  				} // else
			  			} // while
			  			
			  			// get the first one and put it at the end
			  			// cause the last one (currently in haseToBeFirst) will change
			  			// with this one
			  			var hasToBeLast = IS24_ODW.placements.shift();
			  			IS24_ODW.placements.push(hasToBeLast);
			  			
			  			// put back the saved placements from the beginning and the first one
			  			IS24_ODW.placements.unshift(hasToBeFirst);
			  			for(var j = 0; j < tempArray.length; j++) {
			  				IS24_ODW.placements.unshift(tempArray[j]);
			  			} // for
			  			
			  			// decrement counter, cause otherwise we would miss one placement
			  			i--;
			  		} // else
		  		} // if
		  		
		  		// we fixed one
	  			placementsToFix--;
	  		} // if
	  	} // for
	  } // repairFixedPlacements
	  
	  function isOdwCell(id) {
	  	return id.substring(0, 8) == "odwCell_" || isSpecialOdwCell(id);
	  } // isOdwCell
	  
	  function isSpecialOdwCell(id) {
	  	return id.substring(0, 15) == "specialOdwCell_";
	  } // isSpecialOdwCell
	  
	  function specialOdwCellToNonSpecialOdwCell(id) {
	  	if(isSpecialOdwCell(id)) {
	  		var theCell = document.getElementById(id);
	  		theCell.id = "o" +id.substring(8, id.length);
	  		return theCell.id;
	  	} // if
	  } // specialOdwCellToNonSpecialOdwCell
	  
	 
	  function refreshDom() {
	  	var row = document.getElementById(IS24_ODW.containerId);
	  		if(row.hasChildNodes()) {
	  			while(row.firstChild) {
	  				row.removeChild(row.firstChild);
	  			} // while
	  		} // if
	  	
	  	var rowIndex = -1;
	  	for(i = 0; i < IS24_ODW.placements.length; i++) {
	  		if((i % IS24_ODW.numberOfPlacementsToShow) == 0) {
	  			rowIndex++;
	  		} // if
	  		
	  		var placementCell = IS24_ODW.placements[i];
	  		placementCell.style.display = rowIndex == 0 ? "" : "none"; 
	  		row.appendChild(placementCell);
	  	} // for
	  } // refreshDom
	  
	  function restartScrollOdWs(n, time, numberOfPlacementsToScroll) {
	    if ( IS24_ODW.odwInterval != null ) {
	      window.clearInterval(IS24_ODW.odwInterval);
	      IS24_ODW.odwInterval = null;
	    } // if
	    
	    IS24_ODW.numberOfPlacementsToShow = n;
	    IS24_ODW.numberOfPlacementsToScroll = numberOfPlacementsToScroll;
	    IS24_ODW.scrollToLeft = (numberOfPlacementsToScroll > 0);
	    initPlacementsArray();
 	    IS24_ODW.odwInterval = window.setInterval("scrollOdWs()", time);
	  }
