﻿if (top.location != self.location) {top.location=self.location;}
jQuery(document).ready(function() {
	var c=$.cookie('hiddenmsg');
	if (c==1) list_showright(1);
});

function login_showhide() {
	if (document.getElementById('login2').style.display =="") {
		document.getElementById('login2').style.display = "none";
		document.getElementById('login1').style.display = "";
	} else {
		document.getElementById('login2').style.display = "";
		document.getElementById("login_uname").focus();
		document.getElementById('login1').style.display = "none";
	}
	return false;
}
var msg = "www.lysite.cn" ;
window.status = msg;

function showdingyue() {
	document.getElementById('email').focus();return false;
}

function list_showright(ac) {
	if (ac==1) {
		document.getElementById('connter2right').style.display = "none";
		document.getElementById('listmsgopen').style.display = "";
		document.getElementById('connter2left').className = "listmaxwidth";
		$.cookie('hiddenmsg',1,{path: '/'});

	} else {
		document.getElementById('connter2right').style.display = "";
		document.getElementById('listmsgopen').style.display = "none";
		document.getElementById('connter2left').className = "listminwidth";
		$.cookie('hiddenmsg',null,{path: '/'});
	}
}

function checkemail() {
	m=document.getElementById('email').value;
	
	var pattern = /^([a-zA-Z0-9_-])+@([a-zA-Z0-9_-])+(.[a-zA-Z0-9_-])+/; 
	if (pattern.test(m)) return true;
	else alert('非法的Email格式');
	return false;
}
function posted(v) {
	v=v.split("|"); 

	if (v[0]=='1') {
		document.getElementById('email_sub2').style.display = "none";
		document.getElementById('email_sub1').style.display = "";
	} else {
		alert(v); 
	}
}

var oldid=0;
function showsearch(id) {
	document.getElementById('sa'+oldid).className = "";
	document.getElementById('sul'+oldid).style.display = "none";

	document.getElementById('sa'+id).className = "searchpagenavon";
	document.getElementById('sul'+id).style.display = "";
	oldid=id;
}

function select_age(v,name) {
	v=v.split("|"); 

	eval("document."+name+".i1a.value = "+v[0]);
	eval("document."+name+".i1b.value = "+v[1]);
}
o
