<script language="JavaScript">
<!--
function display( dis, hid ){
document.getElementById(hid).style.display="none";
document.getElementById(dis).style.display="";
}
function checkintst(str,check){
if(str == null || str == '') return;
var aIndex = str.split(',');
for(i=0;i < aIndex.length;i++)
{
var node = document.getElementById('interest'+aIndex[i]);
node.checked = check;
}
}
var types = [[true,'1,2,3,4,5,6,7'],
[true,'8,9,10,11,12'],
[true,'19,20,21,22,37'],
[true,'13,14,15,16,17,18'],
[true,'23,24,25,26,27'],
[true,'28,29,30,31'],
[true,'32,33,34,35,36']
];
function checktype( index ){
checkintst( types[index][1],types[index][0] );
types[index][0] = types[index][0]?false:true;
}
var allchecked = false;
function checkall(){
allchecked = allchecked?false:true;
for(i=1;i<=37;i++){
var node = document.getElementById('interest'+i);
node.checked = allchecked;
}
var listnode = document.getElementsByName("checkbox");
for( i=0; i < listnode.length; i++ ){
listnode[i].checked = allchecked;
}
for( i=0; i < 7; i++ ){
types[i][0] = allchecked?false:true;
}
}
function doSubmit(){
var checklist = document.getElementsByName("interest");
for( i = 0; i < checklist.length; i++ ){
if ( checklist[i].checked ){
return true;
}
}
document.getElementById("divMsg").style.display = "";
return false;
}
///////////
var gHost = document.domain; // g1a1.mail.126.com
var gSid = "ABdQusFyYETAsgdm";
var gUser = "heilong05";
var gHuodong = "00000000";
var sMainUrl = "/cgi/ldapapp?funcid=main&sid="+gSid;
var sPostUrl;
function setUrls(){
if(document.domain == "163.com"){
sPostUrl = "http://uinfo.mail.163.com/servlet/userinfo/update3";
}else if(document.domain == "126.com"){
sPostUrl = "http://uinfo.mail.126.com/servlet/userinfo/update3";
}
var frm = document.getElementById("surveyForm");
var picurl = document.getElementById("picurl");
frm.action = sPostUrl;
frm.domain.value = document.domain; // 126.com
frm.username.value = gUser;
frm.host.value = gHost;
frm.sid.value = gSid;
frm.huodong.value = gHuodong;
picurl.onclick=function(){
window.location = sMainUrl;
return false;
}
}
function isSet(){
var gHuodong = document.userform.huodong_option.value;
if(gHuodong.length != 0 && gHuodong.substring(7,8)=="1"){
window.location = sMainUrl;
}
}
///////////
//-->
</script>
评论