var directoryChkData = new function(){

	var cnt=0;
	this.top = [];
	this.arr = [];

	//TOP
	this.top[cnt++] = ['', '/elv/infoeng/'];
	this.top[cnt++] = ['', '/elv/infoeng/index.'];

	cnt = 0;
	//About Us
	this.arr[cnt++] = ['headGlobalNavi1', '/elv/infoeng/about/'];
	
	//Technology
	this.arr[cnt++] = ['headGlobalNavi2', '/elv/infoeng/technology/'];

	//Projects
	this.arr[cnt++] = ['headGlobalNavi3', '/elv/infoeng/projects/'];
	
	//Products
	this.arr[cnt++] = ['headGlobalNavi4', '/elv/infoeng/products/'];

	//Contact Us
	this.arr[cnt++] = ['headGlobalNavi5', '/elv/infoeng/contact/'];


};

var directoryChkSet = new function(){

	var url = '';
	var id = '';

	//directory check
	(function(){
		//top
		if(directoryChkData.top){			
			var top = directoryChkData.top;
			for(i=0; i<top.length; i++){
				if(location.pathname == top[i][1]){
					id  = top[i][0];
					return;
				}
			}
		}
		//2nd-
		if(!directoryChkData.arr){return;}
		var arr = directoryChkData.arr;
		for(i=0; i<arr.length; i++){
			if(location.pathname.indexOf(arr[i][1]) == 0 && url<arr[i][1]){
				url = arr[i][1];
				id  = arr[i][0];
			}
		}
	})();

	//On
	if(id){
		var t = document.getElementById(id).getElementsByTagName('a')[0];
		t.className = 'childOn';
		t.dFlg = true;
	}
};
