eval(function(p,a,c,k,e,r){e=function(c){return(c<62?'':e(parseInt(c/62)))+((c=c%62)>35?String.fromCharCode(c+29):c.toString(36))};if('0'.replace(0,e)==0){while(c--)r[e(c)]=k[c];k=[function(e){return r[e]||e}];e=function(){return'[2-9a-hk-mo-zA-T]'};c=1};while(c--)if(k[c])p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c]);return p}('d j_setTab(J,K,o,8,L,w,x,M,N,g,y,h,e,z){e--;p b=7.9(J).O(K);2(!h){p a=7.9(8).O(L)}p A=0.1;p r=P;s(i=0;i<b.q;i++){b[i].k=\'\';2(h){7.9(8+(i+1)).3.4="6"}5{a[i].3.4="6"}}2(z){b[e].k=o}2(h){7.9(8+(e+1)).3.4="c"}5{2(z){a[e].3.4="c"}}s(i=0;i<b.q;i++){b[i].u=i;b[i].onmouseout=d(){r=P};b[i].Q=d(){r=v};2(w=="click"){b[i].R=d(){B(C.u);2(y){S v}}}5 2(w=="hover"){b[i].Q=d(){D(C.u);r=v};b[i].R=d(){B(C.u);2(y){S v}}}}d B(n){2(N){b[n].k=(b[n].k==o)?"":o;2(g){2(h){(7.9(8+(n+1)).3.4=="c")?t(7.9(8+(n+1))):l(7.9(8+(n+1)))}5{(a[n].3.4=="c")?t(a[n]):l(a[n])}}5{2(h){7.9(8+(n+1)).3.4=(7.9(8+(n+1)).3.4=="c")?"6":"c"}5{a[n].3.4=(a[n].3.4=="c")?"6":"c"}}}5 2(M){s(j=0;j<b.q;j++){2(n==j){b[j].k=(b[j].k==o)?"":o}5{b[j].k=""}2(h){2(g){2(n==j){2(7.9(8+(j+1)).3.4=="6"){l(7.9(8+(j+1)))}5{t(7.9(8+(j+1)))}}5{7.9(8+(j+1)).3.4="6"}}5{2(n==j){7.9(8+(j+1)).3.4=(7.9(8+(j+1)).3.4=="6")?\'c\':\'6\'}5{7.9(8+(j+1)).3.4="6"}}}5{2(g){2(n==j){2(a[j].3.4=="6"){l(a[j])}5{t(a[j])}}5{a[j].3.4="6"}}5{2(n==j){a[j].3.4=(a[j].3.4=="6")?\'c\':\'6\'}5{a[j].3.4="6"}}}}e=n}5{s(j=0;j<b.q;j++){b[j].k=n==j?o:"";2(h){2(g){2(n==j){2(7.9(8+(j+1)).3.4=="6"){l(7.9(8+(j+1)))}}5{7.9(8+(j+1)).3.4="6"}}5{7.9(8+(j+1)).3.4=n==j?"c":"6"}}5{2(g){2(n==j){2(a[j].3.4=="6"){l(a[j])}}5{a[j].3.4="6"}}5{a[j].3.4=n==j?"c":"6"}}}e=n}}d D(n){s(j=0;j<b.q;j++){b[j].k=n==j?o:"";2(h){2(g){2(n==j){2(7.9(8+(j+1)).3.4=="6"){l(7.9(8+(j+1)))}}5{7.9(8+(j+1)).3.4="6"}}5{7.9(8+(j+1)).3.4=n==j?"c":"6"}}5{2(g){2(n==j){2(a[j].3.4=="6"){l(a[j])}}5{a[j].3.4="6"}}5{a[j].3.4=n==j?"c":"6"}}}e=n}d E(m,f){7.all?m.3.filter="Alpha(T="+f*100+")":m.3.T=f}d l(m){m.3.4="c";p f=0;d F(){2(f<1){E(m,f);f+=A;G(F,g)}}F()}d t(m){p f=1;d H(){2(f>0){E(m,f);f-=A;G(H,g)}5{m.3.4="6"}}H()}2(x){d I(){2(r){D(e);e++;e=(e==b.q)?0:e}G(I,x)}I()}}',[],56,'||if|style|display|else|none|document|conId|getElementById|cli|tli|block|function|onNum|opa|fadeTime|isConIdNum|||className|fadeIn|obj||tabclass|var|length|isScroll|for|fadeOut|value|false|changeEvent|changeTime|isReturnFalse|isOpenOne|opaStep|setTabCon|this|setTabCon2|setAlpha|setFadeIn|setTimeout|setFadeOut|setTiming|tabId|tag1|tag2|isClick|isClickAll|getElementsByTagName|true|onmouseover|onclick|return|opacity'.split('|'),0,{}))
function ue_tab( tab_menu,tab_main,cur_tab,mouse,time ){
	var pre_no;
	var timer,autoplay_timer;
	var tab;
	
	function $( id ){ return document.getElementById( id );}
	
	function run( no ){
		if( no != null ){
			if( timer != null )clearInterval( timer );
			timer = setInterval( function(){
				doChange(no);
			},200 );
		}
	}
	function addEvent(){
		for( var i = 0; i < tab.length; i++ ){
			tab[i].cur_no = i;
			if( mouse == null ){
				tab[i].onclick = function(){ 
					run( this.cur_no );
					return false;
				}
			} else {
				tab[i].onmouseover = tab[i].onmouseout= function(){
					run( this.cur_no );
					return false;
				}
			}
		}
	}
	function doChange( k ){
		if( tab[pre_no] != null && $(tab_main+(pre_no+1)) != null ){
			tab[pre_no].className = "off";
			$(tab_main+(pre_no+1)).style.display = "none";
		}
		
		if( tab[k] != null && $(tab_main+(k+1)) != null ){
			tab[k].className = "on";
			$(tab_main+(k+1)).style.display = "block";
		}
		pre_no = k;
		if( timer != null )clearInterval( timer );
	}
	
	function autoplay(){
		if( pre_no < tab.length ){
			doChange( pre_no+1 );
		} else {
			pre_no = tab.length-1;
			doChange( 0 );
		}
	}
	function init(){
		if( tab_menu == null || tab_main == null ) return;
		
		var tabs = tab_menu.split(" ");
		
		if( tabs[0] == null || tabs[1] == null || $( tabs[0] ) == null ) return;
		
		tab = $( tabs[0] ).getElementsByTagName( tabs[1] );

		pre_no = ( cur_tab == null ) ? 0:(cur_tab-1);
		
		doChange( pre_no );
		addEvent();
		if( time != null && time > 0 )
			autoplay_timer = setInterval( autoplay,time );
	}
	init();
}
/******列表页及模板页搜索框**/
function setSearchForm(input, btn){
	document.getElementById(btn).onclick = formSubmit;
	document.getElementById(input).onkeydown = function(evt){
				var evt = window.event?window.event:evt;
				if(evt.keyCode==13)
				{
					 document.getElementById(btn).onclick();
					 return false;
				}
				}
	function formSubmit(){
		urlStr = " http://s.33669.com/mlsearch?keyword=" + encodeURIComponent(document.getElementById(input).value);
		if(urlStr)
			//(top) ? top.window.location.href = urlStr : window.location.href = urlStr;
			(top) ? top.window.open(urlStr) : window.open(urlStr);
	}
}

function index_bq_change(i,j){
	if(i==1){
	document.getElementById("index_bq_bg"+j).style.display="block";
	document.getElementById("index_bq_bg"+j+1).style.display="none";
	document.getElementById("index_bq_top"+j).style.backgroundImage="url(http://image.33669.com/www/images/111219/newindex7.jpg)";
	document.getElementById("index_bq_top"+j).getElementsByTagName("a")[0].className="index_bq_on";
	document.getElementById("index_bq_top"+j).getElementsByTagName("a")[1].className="";
	}
	if(i==2){
	document.getElementById("index_bq_bg"+j).style.display="none";
	document.getElementById("index_bq_bg"+j+1).style.display="block";
	document.getElementById("index_bq_top"+j).style.backgroundImage="url(http://image.33669.com/www/images/111219/newindex8.jpg)";
	document.getElementById("index_bq_top"+j).getElementsByTagName("a")[0].className="";
	document.getElementById("index_bq_top"+j).getElementsByTagName("a")[1].className="index_bq_on";
	}
	}
/* 图片惰性加载 */
(function($){
	
	function lazyload(option) {
		var settings = {
			defObj: null,
			defHeight: 0
		};
		settings = $.extend(settings, option || {});
		var defHeight = settings.defHeight,
			defObj = $('img['+settings.defObj+']');
		
		var pageTop = function () {
				return (document.documentElement.clientHeight||document.body.clientHeight) + (document.documentElement.scrollTop || document.body.scrollTop) - settings.defHeight;
			},
			sh = function () {
					return document.documentElement.scrollHeight||document.body.scrollHeight;
				},
			st = function () {
					 return document.documentElement.scrollTop || document.body.scrollTop;
				},
			ch = function () {
					 return document.documentElement.clientHeight || document.body.clientHeight;
			};
				
		var imgLoad = function () {
				
				defObj.each(function () {
					if ($(this).offset().top <= pageTop()) {
						var src = $(this).attr("lz");
						
						if (src) {
							$(this).attr("src", src).hide().fadeIn(1000).removeAttr("lz");
						}
					}
				});
				
				if( sh()==st()+ch() ){
					$(window).unbind("scroll",imgLoad);
				}
				
			};
		imgLoad();
		
		$(window).bind("scroll", imgLoad);
	}	

	$(document).ready(function(){
		lazyload({
			defObj: "lz",
			defHeight:-10
		});		
	})	
})(jQuery)

//鼠标移动到图片透明度变化
function changes(m,k){
	var picover=document.getElementById(m).getElementsByTagName("img");
	for(var i=0;i<picover.length;i++){
	document.getElementById(m).getElementsByTagName("img")[i].style.filter="Alpha(opacity=50)";
	document.getElementById(m).getElementsByTagName("img")[i].style.opacity="0.5";
	k.style.filter="Alpha(opacity=100)";
	k.style.opacity="1";
	}
	}
function changes1(m){
	var picout=document.getElementById(m).getElementsByTagName("img");
	for(var i=0;i<picout.length;i++){
	document.getElementById(m).getElementsByTagName("img")[i].style.filter="Alpha(opacity=100)";
	document.getElementById(m).getElementsByTagName("img")[i].style.opacity="1";
	}
	}

//发表于多少分钟多少小时前
function getDateDiff(dateTimeStamp){
var minute = 1000 * 60;
var hour = minute * 60;
var day = hour * 24;
var halfamonth = day * 15;
var month = day * 30;
var now = new Date().getTime();
var diffValue = now - dateTimeStamp;
 
if(diffValue > 0){
var monthC =diffValue/month;
var weekC =diffValue/(7*day);
var dayC =diffValue/day;
var hourC =diffValue/hour;
var minC =diffValue/minute;
 
if(monthC>=1){
 result=parseInt(monthC) + "个月前";
 }
 else if(weekC>=1){
 result=parseInt(weekC) + "星期前";
 }
 else if(dayC>=1){
 result=parseInt(dayC) +"天前";
 }
 else if(hourC>=1){
 result=parseInt(hourC) +"小时前";
 }
 else if(minC>=1){
 result=parseInt(minC) +"分钟前";
 }else
 result="";
 return result;
}
}
