//<![CDATA[
	
	// DOM 개체 지속적 깜빡이 효과 
	function _visual_highlight(id, term) {
		if(!term) var term = 2000;
		
		new Effect.Opacity(id, { from: 0, to: 1 });
		setTimeout("_visual_highlight('"+id+"')", term);
	}

	
	
	// 퀵바 최근 본 상품/업체 2009.09.21
	var Recent = {
		current_seq: 0,
		total: 0,
		term: 2,
		dom_list: null,
		init: function(request_uri) {
			this.float = new Floating($('quick'), 120, 10, 10);
			ajax_call(request_uri);
		},
		next: function() {
			if(!this._load_dom()) return;
			if(this.total - (this.current_seq+1) < this.term) {
				alert('마지막 페이지입니다.');
				return
			}
			for(var i=0; i < this.term; i++) {
				if(this.dom_list[this.current_seq]) this.dom_list[this.current_seq].hide();
				if(this.dom_list[this.current_seq + this.term]) this.dom_list[this.current_seq + this.term].show();
				this.current_seq++;
			}
		},
		prev: function() {
			if(!this._load_dom()) return;
			if(this.current_seq < 1) {
				alert('첫 페이지입니다.');
				return
			}
			this.current_seq -= this.term;
			for(var i=this.current_seq; i < this.current_seq+this.term; i++) {
				if(this.dom_list[i+this.term]) this.dom_list[i+this.term].hide();
				if(this.dom_list[i]) this.dom_list[i].show();
			}
		},
		_load_dom: function() {
			if(this.dom_list == null) {
				this.dom_list = $$('a.quick_product');
				this.total = this.dom_list.length
			}
			if(this.total == 0) {
				alert('최근 본 상품/업체 내역이 없습니다.');
				return false;
			}
			return true;
		}
	};

	
	//플래시 메뉴 관련
	var FlashGNB = {
		div_obj: null,
		subShow: function() {
			this._obj().style.zIndex = 9999;
			this._obj().style.height = '78px';
		},
		subHide: function() {
			this._obj().style.zIndex = null;
			this._obj().style.height = '39px';
		},
		_obj: function() {
			if(this.div_obj == null) this.div_obj = $('flashGNB');
			return this.div_obj
		}
	};
	
	
	
	// 가장 하단으로 스크롤
	function scroll_to_bottom() {  
		Effect.ScrollTo('baseFooter');
	} 

	// 가장 상단으로 스크롤
	function scroll_to_top() {  
		if($('baseTop')){
      Effect.ScrollTo('baseTop');
    }else if($('baseTop_v2')){
      Effect.ScrollTo('baseTop_v2');
    }
	} 
	
	//뉴스탭 액션
	function newsChange(category) {
		$$('div.nwsmenu_tabs li').each(function(e) {
			if(e.getAttribute('category') == category) e.addClassName('on');
			else e.removeClassName('on');
		} );
		
		$$('span.news_tab').each(function(e) {
			if(e.getAttribute('category') == category) e.show();
			else e.hide();
		} );
		
	}
	
	
	
	
	
	
	
	
//]]>
