// JavaScript Document
	<!--to hiding script from old browsers
	function GetScreenRealSize(type){
		if(type == "width"){
			return(screen.availWidth);
		}else if(type == "height"){
			return(screen.availHeight);
		}
	}

	function GetWindowRealSize(type){
		if(type == "width"){
			if(usr.ICAB || usr.OPERA){
				return(window.innerWidth);
			}else if(d.all){
				return(document.body.clientWidth);
			}else if(d.layers || d.getElementById){
				return(window.innerWidth);
			}
		}else if(type == "height"){
			if(usr.ICAB || usr.OPERA){
				return(window.innerHeight);
			}else if(d.all){
				return(document.body.clientHeight);
			}else if(d.layers || d.getElementById){
				return(window.innerHeight);
			}
		}
	}

	function getHeight(idName) {
		if(usr.checkObj == 2){
			return d.all(idName).style.pixelHeight;
		}else if(usr.checkObj == 3 || usr.checkObj == 4){
			return parseInt(d.getElementById(idName).offsetHeight);
		}else if(usr.checkObj == 1){
			return d.layers[idName].clip.height;
		}
	}

	function getWidth(idName) {
		if(usr.checkObj == 2){
			return d.all(idName).style.pixelWidth;
		}else if(usr.checkObj ==3 || usr.checkObj ==4){
			return parseInt(d.getElementById(idName).offsetWidth);
		}else if(usr.checkObj == 1){
			return d.layers[idName].clip.width;
		}
	}

	function getTop(idName){
		if(usr.checkObj == 3 || usr.checkObj == 4){
			return parseInt(d.getElementById(idName).style.top);
		}else if(usr.checkObj == 2){
			return d.all(idName).style.pixelTop;
		}else if(usr.checkObj == 1){
			return d.layers[idName].top;
			/*return d.layers[idName].pageX;*/
		}
	}

	function getLeft(idName){
		if(usr.checkObj == 3 || usr.checkObj == 4){
			return parseInt(d.getElementById(idName).style.left);
		}else if(usr.checkObj == 2){
			return d.all(idName).style.pixelLeft;
		}else if(usr.checkObj == 1){
			return d.layers[idName].left;
			/*return d.layers[idName].pageY;*/
		}
	}

	function getWindowWidth(){
		if(usr.WinIE6s){
			return d.documentElement.clientWidth;
		}else if(usr.OPERA || (usr.Mac && (usr.checkObj == 1 || usr.OPERA))){
			return window.innerWidth;
		}else if(usr.Win && usr.checkObj == 1){
			return window.innerWidth - 16;
		}else if(usr.checkObj == 4){
			return window.innerWidth - 15;
		}else if(usr.checkObj == 2 || usr.checkObj == 3){
			return d.body.clientWidth;
		}
	}

	function getWindowHeight(){
		if(usr.WinIE6s){
			return d.documentElement.clientHeight;
		}else if(usr.OPERA || (usr.Mac && (usr.checkObj == 1 || usr.OPERA))){
			return window.innerHeight;
		}else if(usr.Win && usr.checkObj == 1){
			return window.innerHeight - 16;
		}else if(usr.checkObj == 4){
			return window.innerHeight - 15;
		}else if(usr.checkObj == 2 || usr.checkObj == 3){
			return d.body.clientHeight;
		}
	}

	function getWindowXOffset(){
		if(usr.WinIE6s || usr.modeStandard){
			return d.body.parentNode.scrollLeft;
		}else if(usr.checkObj == 2 || usr.checkObj == 3){
			return d.body.scrollLeft;
		}else if(usr.checkObj == 1 || usr.checkObj == 4){
			return window.pageXOffset;
		}
	}

	function getWindowYOffset(){
		if(usr.WinIE6s || usr.modeStandard){
			return d.body.parentNode.scrollTop;
		}else if(usr.checkObj == 2 || usr.checkObj == 3){
			return d.body.scrollTop;
		}else if(usr.checkObj == 1 || usr.checkObj == 4){
			return window.pageYOffset;
		}
	}

	function getDocWidth(){
		if(usr.allObj){
			return getTagLeft('end') + 1;
		}
	}
	function getDocHeight(){
		if(usr.allObj){
			return getTagTop('end') + 1;
		}
	}

	function getDistanceMaxX(){
		if(usr.allObj){
			return (getDocWidth() - getWindowWidth());
		}
	}
	function getDistanceMaxY(){
		if(usr.allObj){
			return (getDocHeight() - getWindowHeight());
		}
	}

	function getVisibility(idName){
		if(usr.checkObj == 2 || usr.checkObj == 3){
			if(d.all(idName).style.visibility=='')return 'inherit'
			return d.all(idName).style.visibility
		}else if(usr.checkObj == 4){
			if(d.getElementById(idName).style.visibility=='')return 'inherit'
			return d.getElementById(idName).style.visibility
		}else if(usr.checkObj == 1){
			if(d.layers[idName].visibility=='show')return 'visible'
			if(d.layers[idName].visibility=='hide')return 'hidden'
			if(d.layers[idName].visibility=='inherit')return 'inherit'
		}
	}

	function setObj(idName){
		return d.all ? d.all(idName) : d.getElementById ? d.getElementById(idName) : d.layers[idName];
	}

	function getTagLeft(idName) {
		var obj = setObj(idName);
		var tagCoords = new Object();
		if((usr.checkObj == 2) || (usr.checkObj == 3) || (usr.checkObj == 4)) {
			tagCoords.x = obj.offsetLeft;
			while ((obj = obj.offsetParent) != null) {
				tagCoords.x += obj.offsetLeft;
			}
		} else if(usr.checkObj == 1) {
			tagCoords.x = d.anchors[idName].x;
		}if((tagCoords.x*0)==0){
			return tagCoords.x;
		}else{
			return idName;
		}
	}

	function getTagTop(idName) {
		var obj = setObj(idName);
		var tagCoords = new Object();
		if((usr.checkObj == 2) || (usr.checkObj == 3) || (usr.checkObj == 4)) {
			tagCoords.y = obj.offsetTop;
			while ((obj = obj.offsetParent) != null) {
				tagCoords.y += obj.offsetTop;
			}
		} else if(usr.checkObj == 1) {
			tagCoords.y = d.anchors[idName].y;
		}if((tagCoords.y*0) == 0){
			if(usr.Mac && usr.Moz){
				return (tagCoords.y - 12);
			}else if((usr.Win && usr.Moz) || (usr.Mac && usr.SAFARI)){
				return (tagCoords.y - 9);
			}else{
				return (tagCoords.y);
			}
		}else{
			return idName;
		}
	}

	/*PageScroller*/
	var nd_pageScrollTimer;
	function nd_pageScroll(toX,toY,frms,frX,frY) {
		if(nd_pageScrollTimer) clearTimeout(nd_pageScrollTimer);
		var spd = usr.Moz?2:usr.Mac ? 14 :16;
		var actX = getWindowXOffset();
		var actY = getWindowYOffset();
		if(!toX || toX < 0) toX = 0;
		if(!toY || toY < 0) toY = 0;
		if(!frms) frms = (usr.Mac&&(usr.OPERA||usr.NS6))?3:usr.NS6?4:usr.NS?10:5;
		if(!frX) frX = 0 + actX;
		if(!frY) frY = 0 + actY;

		frX += (toX - actX) / frms;
		if (frX < 0) frX = 0;
		frY += (toY - actY) / frms;
		if (frY < 0) frY = 0;
		var posX = Math.ceil(frX);
		var posY = Math.ceil(frY);
		window.scrollTo(posX, posY);
		if((Math.floor(Math.abs(actX - toX)) < 1) && (Math.floor(Math.abs(actY - toY)) < 1)){
			clearTimeout(nd_pageScrollTimer);
			window.scroll(toX,toY);
		}else if(posX != toX || posY != toY){
			nd_pageScrollTimer = setTimeout("nd_pageScroll("+toX+","+toY+","+frms+","+frX+","+frY+")",spd);
		}else{
			clearTimeout(nd_pageScrollTimer);
		}
	}

	function toAnchor(idName,longitudinalAdj,traverser) {
		if(usr.allObj){
			if(!!idName){
				var anchorX = traverser ? getTagLeft(idName) : 0;
				var anchorY = longitudinalAdj? getTagTop(idName)-longitudinalAdj : getTagTop(idName)-20;
				var dMaxX = getDistanceMaxX();
				var dMaxY = getDistanceMaxY();
				if(((anchorX*0) == 0)||((anchorY*0) == 0)){
					var setX = (anchorX<1)?0:(anchorX>dMaxX)?dMaxX:anchorX;
					var setY = (anchorY<1)?0:(anchorY>dMaxY)?dMaxY:anchorY;
					nd_pageScroll(setX,setY);
				}else{
					location.hash = idName;
				}
			}else{
				nd_pageScroll(0,0);
			}
		}else{
			!!idName ? location.hash = idName : location.hash = "top";
		}
	}
	// end hiding script from old browsers-->
	
	
	
	//CSS SELECT ?
	
	<!--to hiding script from old browsers
	/*for barbet 5.x*/
	/*Set Up Object*/
	var bAgent = navigator.userAgent;
	var bName = navigator.appName;
	var bPlugins = navigator.plugins;
	var d = document;
	
	function sniffer(){
		/*OS*/
		this.Win = bAgent.indexOf("Win",0) != -1 ? 1 :0;
		this.Mac = bAgent.indexOf("Mac",0) != -1 ? 1 :0;
		this.MacOSX = ((bAgent.indexOf("Mozilla") != -1) && (bAgent.indexOf("Mac OS X") != -1)) ? 1 :0;
		if(bPlugins){for(i=0;i<bPlugins.length;i++){if(this.Mac && (bPlugins[i].filename.indexOf("QuickTime Plugin.plugin")!=-1)){this.MacOSX=true;}}}
		
		/*Browser*/
		this.IE = ((bAgent.indexOf("MSIE") != -1) && (bAgent.indexOf("Opera") == -1)) ? 1 :0;
		this.NS = ((bName == "Netscape") && (bAgent.indexOf("Opera") == -1)) ? 1 :0;
		this.NC = ((bName == "Netscape") && (bAgent.indexOf("Gecko") == -1) && (bAgent.indexOf("Opera") == -1)) ? 1 :0;
		this.Gecko = (bAgent.indexOf("Gecko") != -1) ? 1 :0;
		this.Moz = ((bAgent.indexOf("Gecko") != -1) && (bAgent.indexOf("Safari",0) == -1)) ? 1 :0;
		this.OPERA = bAgent.indexOf("Opera",0) != -1 ? 1 :0;
		this.SAFARI = bAgent.indexOf("Safari",0) != -1 ? 1 :0;
		this.ICAB = bAgent.indexOf("iCab",0) != -1 ? 1 :0;
		
		this.IE3 = (bAgent.indexOf('MSIE 3.',0) != -1);
		this.MacIE4 = (this.Mac && (bAgent.indexOf('MSIE 4.',0) != -1));
		this.MacIE45 = (this.Mac && (bAgent.indexOf('MSIE 4.5',0) != -1));
		this.MacIE5 = (this.Mac && (bAgent.indexOf('MSIE 5.',0) != -1));
		this.NS60 = (bAgent.indexOf("Netscape6/6.0") != -1);
		this.NS6 = (bAgent.indexOf("Netscape6/") != -1);
		this.NS7 = (bAgent.indexOf("Netscape/7") != -1);
		
		/*Object*/
		/*NS4 = 1, IE4 = 2, IE5+,OPERA5,7 = 3, NS6+,SAFARI,OPERA6 = 4, others = 0*/
		this.checkObj = d.all?(d.getElementById?3:2):(d.getElementById?4:(d.layers?1:0));
		this.allObj = ((this.checkObj == 1) || (this.checkObj == 2) || (this.checkObj == 3) || (this.checkObj == 4));
		this.checkObj4 = (d.getElementById && !d.all) ? 1 :0;
		this.checkObj3 = (d.getElementById && d.all) ? 1 :0;
		this.checkObj2 = (d.all && !d.getElementById) ? 1 :0;
		this.checkObj1 = d.layers ? 1 :0;
		
		/*Compat Mode*/
		this.modeStandard = d.compatMode == "CSS1Compat" ? 1 : 0;
		this.modeQuirks = d.compatMode == "BackCompat" ? 1 : 0;
		
		this.WinIE6s = (this.Win && this.IE && this.modeStandard && ((bAgent.indexOf('MSIE 6.',0) != -1) || (bAgent.indexOf('MSIE 7.',0) != -1)));
		this.WinIE6q = (this.Win && this.IE && this.modeQuirks && ((bAgent.indexOf('MSIE 6.',0) != -1) || (bAgent.indexOf('MSIE 7.',0) != -1)));
		
		return this;
	}
	var usr = new sniffer;

	/*window open*/
	var ratedWidth = ratedHeight = "";
	function subWin(subUrl,subName,subWidth,subHeight,subBar,subLoca,subMenu) {
		window.parent.name = "ffMain";
		if(usr.allObj){
			subWidth += 0;subHeight += 0;
			if(usr.Mac && usr.IE){
				subWidth -= 16;subHeight += 0;
			}
			var screenX = GetScreenRealSize("width");
			var screenY = GetScreenRealSize("height");
			var realSizeWidth = GetWindowRealSize("width");
			var realSizeHeight = GetWindowRealSize("height");
			ratedWidth = subWidth;
			ratedHeight = subHeight;
			if(!!screenX && !!realSizeWidth && subWidth > screenX)ratedWidth = realSizeWidth;
			if(!!screenY && !!realSizeHeight && subHeight > screenY)ratedHeight = realSizeHeight;
			if(!subBar)subBar = "yes";
			if(!subLoca)subLoca = "yes";
			if(!subMenu)subMenu = "yes";
			if(!subName)subName = "Sub";
			windowSub = ("window" + subName);
			window[windowSub] = window.open(subUrl,subName,"width="+ratedWidth+",height="+ratedHeight+",location="+subLoca+",menubar="+subMenu+",personalbar=no,directories=no,scrollbars="+subBar+",status=yes,toolbar=no,copyhistory=no,resizable=yes,top=0,left=0");
			if(!usr.IE3)window[windowSub].focus();
			if(!d.all)window[windowSub].moveTo(0,0);
			if (!!usr.IE && (usr.checkObj2 || usr.checkObj3)) { window[windowSub].opener = self; }
		}
	}

	IE3 = (navigator.userAgent.indexOf('MSIE 3.',0) != -1);
	if(!IE3){window.focus();}
	
	// end hiding script from old browsers-->



	
function nd_setActiveStyleSheet(title) {
  var i, a, main;
  for(i=0; (a = document.getElementsByTagName("link")[i]); i++) {
    if(a.getAttribute("rel").indexOf("style") != -1 && a.getAttribute("title")) {
      a.disabled = true;
      if(a.getAttribute("title") == title) a.disabled = false;
    }
  }
}

function getActiveStyleSheet() {
  var i, a;
  for(i=0; (a = document.getElementsByTagName("link")[i]); i++) {
    if(a.getAttribute("rel").indexOf("style") != -1 && a.getAttribute("title") && !a.disabled) return a.getAttribute("title");
  }
  return null;
}

function getPreferredStyleSheet() {
  var i, a;
  for(i=0; (a = document.getElementsByTagName("link")[i]); i++) {
    if(a.getAttribute("rel").indexOf("style") != -1
       && a.getAttribute("rel").indexOf("alt") == -1
       && a.getAttribute("title")
       ) return a.getAttribute("title");
  }
  return null;
}

function createCookie(name,value,days) {
  if (days) {
    var date = new Date();
    date.setTime(date.getTime()+(days*24*60*60*1000));
    var expires = "; expires="+date.toGMTString();
  }
  else expires = "";
  document.cookie = name+"="+value+expires+"; path=/";
}

function readCookie(name) {
  var nameEQ = name + "=";
  var ca = document.cookie.split(';');
  for(var i=0;i < ca.length;i++) {
    var c = ca[i];
    while (c.charAt(0)==' ') c = c.substring(1,c.length);
    if (c.indexOf(nameEQ) == 0) return c.substring(nameEQ.length,c.length);
  }
  return null;
}

window.onload = function(e) {
  var cookie = readCookie("style");
  var title = cookie ? cookie : getPreferredStyleSheet();
  nd_setActiveStyleSheet(title);
}

window.onunload = function(e) {
  var title = getActiveStyleSheet();
  createCookie("style", title, 365);
}

var cookie = readCookie("style");
var title = cookie ? cookie : getPreferredStyleSheet();
nd_setActiveStyleSheet(title);

(function(){

	/*Use Object Detection to detect IE6*/
	var  m = document.uniqueID /*IE*/
	&& document.compatMode  /*>=IE6*/
	&& !window.XMLHttpRequest /*<=IE6*/
	&& document.execCommand ;
	
	try{
		if(!!m){
			m("BackgroundImageCache", false, true) /* = IE6 only */ 
		}
		
	}catch(oh){};
})();



// 20100519

jQuery.noConflict();

jQuery(function() {
	jQuery("#i_search_input")
		.focus(function() {
			jQuery(this).parent().css("background-image", "url(/nd_share/img/search_input_fc.jpg)");
		})
		.blur(function() {
			jQuery(this).parent().css("background-image", "url(/nd_share/img/search_input.jpg)");
		});
});


