	
	// PopUp WIndow
	
	function soopaPop(URL, width, height, resize, scroll) {
	day = new Date();
	id = day.getTime();
	eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=' + scroll + ',location=0,statusbar=0,menubar=0,resizable=' + resize +',width=' + width + ',height=' + height + ',innerWidth=' + width + ',innerHeight=' + height + ',screenX=150,screenY=150,left=150,right=150');");
	}

	var currentSector = 9;
	
	function scrollContent(newSector){

		var count = 0;
		var startingX = (currentSector - 9) * 409;
		var newX = (newSector - 9) * 409;
	
		if(startingX < newX){
			while(startingX < newX){
				count = count + 0.01;			
				window.frames.screenshots.scrollBy((startingX/newX)*count,0);
				startingX+=count;
			}
		}else if(startingX > newX){
			while(startingX > newX){
				count = count + 0.01;			
				window.frames.screenshots.scrollBy(-count,0);
				startingX-=count;
			}
		}
		window.frames.screenshots.scrollTo(newX,0);
		currentSector = newSector;
	}

	
	
	function shiftRanks(form, rank, clientId){

		//rank: the new rank value
		//clientId: the client whos rank is changing
	
		var str;
		var currentClientId;

		//if the rank is currently in use then shift all >= ranks
		if(isRankBeingUsed(form,rank,clientId)){

			//go throught each form field
			for(x=0; x < form.length; x++){
			
				str = new String(form.elements[x].name);
				currentClientId = str.substring(7,str.indexOf("][rank]"));
					
				//if it is a rank form field, and the value >= rank, and it is not the field where the onchange event came from
				if(str.indexOf("[rank]") >= 0 && form.elements[x].value >= rank && currentClientId != clientId){ 
		
					form.elements[x].value = parseInt(form.elements[x].value) + 1;
					
				}
			
			}	

		}
	
	}
	
	
	
	
	function isRankBeingUsed(form, rank, clientId){
	
		//rank: the new rank value
		//clientId: the client whos rank is changing
	
		var str;
		var currentClientId;

		for(x=0; x < form.length; x++){
		
			str = new String(form.elements[x].name);
			currentClientId = str.substring(7,str.indexOf("][rank]"));

			if(str.indexOf("[rank]") >= 0 && form.elements[x].value == rank && currentClientId != clientId){ 

				return true;
			
			}
					
		}	

		return false;
	
	}
	
	
	
	
	// RollOver Buttons
	
<!--
	
	if (document.images) {            // Active Images
	
				
				//Primary Nav
				
	            img1on = new Image();      
	            img1on.src = "images/navHome02.jpg";
	
	            img1off = new Image(); 
	            img1off.src = "images/navHome01.jpg";   
				
				//---
				
				img2on = new Image();      
	            img2on.src = "images/navProfile02.jpg";
	
	            img2off = new Image(); 
	            img2off.src = "images/navProfile01.jpg"; 
				
				//---
				
				img3on = new Image();      
	            img3on.src = "images/navClients02.jpg";
	
	            img3off = new Image(); 
	            img3off.src = "images/navClients01.jpg"; 
				
				//---
				
				img4on = new Image();      
	            img4on.src = "images/navPartners02.jpg";
	
	            img4off = new Image(); 
	            img4off.src = "images/navPartners01.jpg"; 
				
				//---
				
				img5on = new Image();      
	            img5on.src = "images/navContact02.jpg";
	
	            img5off = new Image(); 
	            img5off.src = "images/navContact01.jpg"; 
				
				// More
				
				img6on = new Image();      
	            img6on.src = "images/more02.jpg";
	
	            img6off = new Image(); 
	            img6off.src = "images/more01.jpg"; 
				
				//---
				
				img7on = new Image();      
	            img7on.src = "images/more02.jpg";
	
	            img7off = new Image(); 
	            img7off.src = "images/more01.jpg"; 
				
				// Top
				
				img8on = new Image();      
	            img8on.src = "images/top02.jpg";
	
	            img8off = new Image(); 
	            img8off.src = "images/top01.jpg"; 
				
				// Screen Shots Buttons
				
				img9on = new Image();      
	            img9on.src = "images/ssBTN01_02.jpg";
	
	            img9off = new Image(); 
	            img9off.src = "images/ssBTN01_01.jpg"; 
				
				//---
				
				img10on = new Image();      
	            img10on.src = "images/ssBTN02_02.jpg";
	
	            img10off = new Image(); 
	            img10off.src = "images/ssBTN02_01.jpg"; 
				
				//---
				
				img11on = new Image();      
	            img11on.src = "images/ssBTN03_02.jpg";
	
	            img11off = new Image(); 
	            img11off.src = "images/ssBTN03_01.jpg"; 
				
				//---
				
				img12on = new Image();      
	            img12on.src = "images/ssBTN04_02.jpg";
	
	            img12off = new Image(); 
	            img12off.src = "images/ssBTN04_01.jpg"; 
				
				//---
				
				img13on = new Image();      
	            img13on.src = "images/ssBTN05_02.jpg";
	
	            img13off = new Image(); 
	            img13off.src = "images/ssBTN05_01.jpg"; 
				
				//---
				
				img14on = new Image();      
	            img14on.src = "images/ssBTN06_02.jpg";
	
	            img14off = new Image(); 
	            img14off.src = "images/ssBTN06_01.jpg"; 
				
				//---
				
				img15on = new Image();      
	            img15on.src = "images/ssBTN07_02.jpg";
	
	            img15off = new Image(); 
	            img15off.src = "images/ssBTN07_01.jpg"; 
				
				//---
				
				img16on = new Image();      
	            img16on.src = "images/ssBTN02.jpg";
	
	            img16off = new Image(); 
	            img16off.src = "images/ssBTN01.jpg"; 
				
				//---
				
				img17on = new Image();      
	            img17on.src = "images/ssBTN02.jpg";
	
	            img17off = new Image(); 
	            img17off.src = "images/ssBTN01.jpg"; 
				
				// Admin Nav
				
				img18on = new Image();      
	            img18on.src = "../images/adminNavFeature02.jpg";
	
	            img18off = new Image(); 
	            img18off.src = "../images/adminNavFeature01.jpg"; 
				
				//---
				
				img19on = new Image();      
	            img19on.src = "../images/adminNavClients02.jpg";
	
	            img19off = new Image(); 
	            img19off.src = "../images/adminNavClients01.jpg"; 
				
				//---
				
				img20on = new Image();      
	            img20on.src = "../images/adminNavLogout02.jpg";
	
	            img20off = new Image(); 
	            img20off.src = "../images/adminNavLogout01.jpg"; 
				
				// Admin Top
				
				img21on = new Image();      
	            img21on.src = "../images/top02.jpg";
	
	            img21off = new Image(); 
	            img21off.src = "../images/top01.jpg";
				
				     }
	
	// Function to 'activate' images.
	function imgOn(imgName) {
	        if (document.images) {
	            document[imgName].src = eval(imgName + "on.src");
	        }
	}
	
	// Function to 'deactivate' images.
	function imgOff(imgName) {
	        if (document.images) {
	            document[imgName].src = eval(imgName + "off.src");
	        }
	}
	
	// -->

