function getCookie(name){

	var cookie,list,i,equals,match;
	cookie=document.cookie;
	
	if(cookie.length==0){
		return '';
	}
	
	else{
	
		list=cookie.split(';');
		for(i=0;i<list.length;i=i+1){
		equals=list[i].indexOf('=');
		match=list[i].substring(0,equals);
		if(match.substr(0,1)==' '){
		match=match.substr(1);
		}
		if(match==name){
		return list[i].substring(equals+1,list[i].length);
		}
		}
		return '';
	
	}
}


function writePath(n){

document.cookie="pathh="+n;

}


	
$(document).ready(function(){


var fl=0;
var pathLen=($(".breadPath").size());
var g=getCookie('pathh');
//alert("Cookie: "+g);
g=g.split('/').join('');
g=g.split(' ').join('');
			
var te="";

	if(pathLen!=0)
	{
		
		
		for (i=0;i<pathLen;i++)
		{	
			te=$(".breadPath:eq("+i+") a:eq(1)").text();
			te=te.split('/').join('');
			te=te.split(' ').join('');
			//alert(te);
			
			
			if(te==g && g!=""){
			
			if(fl==0){
			$(".breadPath").css("display","none");
			}
			
			$(".breadPath:eq("+i+")").css("display","block");
			
			
			fl=1;
			}
			
		}
		//Remote I/O
		//Remote I / O
		
	
	if (fl==0){
	$(".breadPath").css("display","none");
	$(".breadPath:eq(0)").css("display","block");
	
	}
		
		
	
		
	}
	//g=getCookie('path');

	//alert(g);
	
		
$(".breadPath").css("color","#000000");
$(".breadPath a").css("color","#000000");


});	

