﻿
var area="";

var Industrylists=new Array();
var joblists=new Array();
var Degrees="";
var WORKYEARs="";
var sexs="";
var month="";
var keyword="";
var qproducts="";
var qmarkets="";
var ImagePath = "http://image.51job.com/imehire/ehire2007/default/image/";
var Refresh = "刷新页面";
var ifFromLoad = "ifFromLoad";
var divFromLoad = "divFromLoad";
var strIFLoad = "ifLoad";  
var strDivLoad = "divRefresh";
var strLoad = "正在加载数据";//visibility="hidden";//visible
var data = new Array(0,1,2,3,4,5,7,10);
var profe="";
var Industryk="";
var postsk="";
var agek="";
var dataname=new Array();
var Degreesk="";
function Load()
{
    SelectJobL();
    Clear();
    document.getElementById("actionid").value=0;
    SelectIndex();
    go(10);
    document.getElementById("search").innerHTML='<%=strg %>';
}
function SAREA()
{
    area=document.getElementById("AREAs").value;
    document.getElementById("tAREAs").value=area;
}
function fedu1()
{
    
   
}
function getareaid(o)
{
    var areaid="";
    for(var k=1;k<36;k++)//arrCity arrCityId
    {
        for(var i=0;i<arrCity[k].length;i++)
        {
            if(arrCity[k][i].indexOf(o)>-1)
            {
                areaid=arrCityId[k][i];
            }
        }
        //var opt = new Option(arrCity[k],arrCityId[k]);
        //select_node.options.add(opt);
        
    }
    return areaid;
}
function booljoblist(id)
{
    for(var i=0;i<jobliststemp.length;i++)
    {
        if(jobliststemp[i][1]==id)
        {
            return true;
        }
    }
    return false;
}
function boolIndustrylist(id)
{
    for(var i=0;i<Industryliststemp.length;i++)
    {
        if(Industryliststemp[i][1]==id)
        {
            return true;
        }
    }
    return false;
}
function Industryselect(id,name,o)
{
    if(Industryliststemp.length>=3&&!boolIndustrylist(name))//&&BoolJob(name)
    {
        ClearJob(name,1);
        alert("只能选择3个条件");
        return;
    }
    var k=0;
    if(Industryliststemp!="")
    {
        try
        {
        for(var i=0;i<Industryliststemp.length;i++)
        {
            for(var j=0;j<Industryliststemp[i].length;j++)
            {
                if(Industryliststemp[i][j]==name)
                {
                    Industryliststemp.remove(Industryliststemp[i]);
                    k++;
                }
            }
        }
        }
        catch(o){}
    }
    if(o==0)
    {
    	clickspan(name,"div1");
    }
    if(k==0)
    {
        Industryliststemp[Industryliststemp.length]=new Array(id,name);
    }
    IndustryHTML();
    if(k>0)
    ClearCheckBox(name,"div1");

}
function clickspan(id,divname)
{
	var obj = document.getElementById(divname).getElementsByTagName("input");
        for(var i = 0;i < obj.length; i++)
        {	
	    if(obj[i].type == "checkbox" &&obj[i].getAttribute("att")!=null)
            {
                if(obj[i].getAttribute("att")==id)
                {
		    if(obj[i].checked==false)
		    	obj[i].checked=true;
		    else
			obj[i].checked=false;
		}
	    }
	}
}
function IndustryHTML()
{
    var str="<div id=\"Industrylist\"><table><tr>";
    var strvalue="";
    for(var i=0;i<Industryliststemp.length;i++)
    {
	strvalue+=Industryliststemp[i][1]+"#";
        str+="<td class=\"hand\" onMouseOver=\"this.className='mmmouseover'\" onMouseOut=\"this.className='mmmouseout'\"><input type=\"checkbox\" checked=\"true\" onclick=\"Industryselect('"+Industryliststemp[i][0]+"','"+Industryliststemp[i][1]+"',0);\" name=\""+Industryliststemp[i][0]+"\" id=\""+Industryliststemp[i][0]+"\" value=\""+Industryliststemp[i][1]+"\" att=\""+Industryliststemp[i][1]+"\" /><span class=\"hand\" onclick=\"Industryselect('"+Industryliststemp[i][0]+"','"+Industryliststemp[i][1]+"',0);\">"+Industryliststemp[i][0]+"&nbsp;&nbsp;&nbsp;&nbsp;</span></td>"
    }
    str+="</tr></table></div>";
	
    document.getElementById("Industry").value=strvalue.substring(0,strvalue.length-1);
    document.getElementById("Industrylist").innerHTML=str;
    //<span><input type=\"checkbox\" onclick=\"jobselect('"+s[0]+"','"+s[1]+"');\" name=\""+s[0]+"\" id=\""+s[0]+"\" value=\""+s[1]+"\" att=\""+s[1]+"\" />"+s[0]+"</span>
}
function jobselectL(id,name,o)//0 1
{
    if(jobliststemp.length>=3&&!booljoblist(name))//&&BoolJob(name)
    {
        ClearJob(name,1);
        alert("只能选择3个条件");
        return;
    }
    var k=0;
    if(jobliststemp!="")
    {
        try
        {
        for(var i=0;i<jobliststemp.length;i++)
        {
            for(var j=0;j<jobliststemp[i].length;j++)
            {
                if(jobliststemp[i][j]==name)
                {
                    jobliststemp.remove(jobliststemp[i]);
                    k++;
                }
            }
        }
        }
        catch(o){}
    }
    if(o==0)
    {
    	clickspan(name,"divz");
    }
    if(k==0)
    {
        jobliststemp[(jobliststemp.length)]=new Array(id,name);
    }
    jobHTML();
    if(k>0)
    ClearCheckBox(name,"divz");
    //alert(document.getElementById("joblist").innerHTML);
}
function ClearCheckBox(id,divname)
{
	var obj = document.getElementById(divname).getElementsByTagName("input");
        for(var i = 0;i < obj.length; i++)
        {	
	    if(obj[i].type == "checkbox" && obj[i].checked == true&&obj[i].getAttribute("att")!=null)
            {
                if(obj[i].getAttribute("att")==id)
                {
		    obj[i].checked=false;
		}
	    }
	}
}
function jobHTML()
{
    var str="<div id=\"joblist\"><table><tr>";
    var strvalue="";
    for(var i=0;i<jobliststemp.length;i++)
    {
	strvalue+=jobliststemp[i][1]+"#";
        str+="<td class=\"hand\" onMouseOver=\"this.className='mmmouseover'\" onMouseOut=\"this.className='mmmouseout'\"><input type=\"checkbox\" checked=\"true\" onclick=\"jobselectL('"+jobliststemp[i][0]+"','"+jobliststemp[i][1]+"',0);\" name=\""+jobliststemp[i][0]+"\" id=\""+jobliststemp[i][0]+"\" value=\""+jobliststemp[i][1]+"\" att=\""+jobliststemp[i][1]+"\" /><span class=\"hand\" onclick=\"jobselectL('"+jobliststemp[i][0]+"','"+jobliststemp[i][1]+"',0);\">"+jobliststemp[i][0]+"&nbsp;&nbsp;&nbsp;&nbsp;</span></td>"
    }
    str+="</tr></table></div>";
    document.getElementById("postsk").value=strvalue.substring(0,strvalue.length-1);
    document.getElementById("joblist").innerHTML=str;
    //<span><input type=\"checkbox\" onclick=\"jobselect('"+s[0]+"','"+s[1]+"');\" name=\""+s[0]+"\" id=\""+s[0]+"\" value=\""+s[1]+"\" att=\""+s[1]+"\" />"+s[0]+"</span>
}
function BoolJob(id)//1:条件大于3
{
    var obj = document.getElementsByTagName("input");
    for(var i = 0;i < obj.length; i++)
    {
        if(obj[i].type == "checkbox" && obj[i].checked == true&&obj[i].getAttribute("att")!=null)
        {
            if(obj[i].getAttribute("att")==id)
            {
                return true;
            }
            //document.getElementById("postsk").value = obj[i].name;
            //document.getElementById("postss").value = obj[i].getAttribute("att");
            //postsk=obj[i].name;
        }
    }
    return false;
}
function ClearJob(id,o)//1:条件大于3
{
    var obj = document.getElementsByTagName("input");
    for(var i = 0;i < obj.length; i++)
    {
        if(obj[i].type == "checkbox" && obj[i].checked == true&&obj[i].getAttribute("att")!=null)
        {
            if(obj[i].getAttribute("att")==id&&o==1)
            {
                obj[i].checked=false;
            }
            //document.getElementById("postsk").value = obj[i].name;
            //document.getElementById("postss").value = obj[i].getAttribute("att");
            //postsk=obj[i].name;
        }
    }
}
function fsex()
{
    sexs=document.getElementById("sexs").value;
    document.getElementById("tsexs").value=area;
}
function fWORKYEARs()
{
    area=document.getElementById("WORKYEARs").value;
    document.getElementById("tWORKYEARs").value=area;
}
function Change()
{
    joblists=new Array();
    var searchmachine=document.getElementById("searchmachine");
    data=new Array();
    var p=0;
    for(var i=0;i<AllData.length;i++)
    {
        var data1=AllData[i].split('#');
        if(data1[0]==searchmachine.value)
        {
            document.getElementById("SearchName").value=data1[1];
            if(data1[0]!="0")
            {
                //document.getElementById("SearchName").value=data1[5];
                //area=data1[2];
            }
            if(data1[2]!="0")
            {
                //document.getElementById("SearchName").value=data1[5];
                dataname[p]=data1[2];
                data[p]=1;
                p++;
                WORKYEARs=data1[2];
            }
            if(data1[3]!="0")
            {
                //document.getElementById("SearchName").value=data1[5];
                dataname[p]=data1[3];
                data[p]=7;
                p++;
            }
            if(data1[4]!="0")
            {
                //document.getElementById("SearchName").value=data1[5];
                dataname[p]=data1[4];
                data[p]=0;
                p++;
                area=data1[4];
            }
            /*
            if(data1[5]!="0")
            {
                //document.getElementById("SearchName").value=data1[5];
                dataname[p]=data1[5];
                data[p]=9;
                p++;
            }
            */
            if(data1[7]!="0")
            {
                //document.getElementById("SearchName").value=data1[5];

                dataname[p]=data1[7];
                data[p]=6;
                p++;
            }
            if(data1[8]!="0")
            {
                //document.getElementById("SearchName").value=data1[5];
                document.getElementById("keywords").value=data1[8];
                keyword=data1[8];
            }
            if(data1[9]!="0")
            {
                //document.getElementById("SearchName").value=data1[5];
                dataname[p]=data1[9];
                data[p]=5;
                p++;
            }
            if(data1[10]!="0")
            {
                //document.getElementById("SearchName").value=data1[5];
                dataname[p]=data1[10];
                data[p]=3;
                p++;
            }
            if(data1[15]!="0")
            {
                //document.getElementById("SearchName").value=data1[5];
                dataname[p]=data1[15];
                data[p]=10;
                p++;
                month=data1[15];
            }
            if(data1[11]!="0")
            {
                //document.getElementById("SearchName").value=data1[5];
                //document.getElementById("LastUpdateTimes").value=data1[8];
                //document.getElementById("LastUpdateTimes").options=data1[8];
            }
            if(data1[13]!="0")
            {
                //document.getElementById("SearchName").value=data1[5];
                document.getElementById("products").value=data1[13];
                qproducts=data1[13];
            }
            if(data1[14]!="0")
            {
                //document.getElementById("SearchName").value=data1[5];
                document.getElementById("Markets").value=data1[14];
                qmarkets=data1[14];
            }
            if(data1[19]!="0")
            {
                //document.getElementById("SearchName").value=data1[5];
                dataname[p]=data1[19];
                data[p]=2;
                p++;
            }
            if(data1[20]!="0")
            {
                //document.getElementById("SearchName").value=data1[5];
                dataname[p]=data1[20];
                data[p]=4;
                p++;
            }
            /*
            var p=0;
            for(var j=0;j<data1.length;j++)
            {
                if(data1[j]!="0")
                {
                    dataname[p]=data1[j];
                    data[p]=j;
                    p++;
                }
            }
            */
        }
    }
    
    Clear();
    //alert("data:"+data.length);
    SelectIndex();
    go(10);
    CZ();
}
function actionsubmit(o)
{
    document.getElementById("actionid").value=o;
    if(o==2)
    {
        Form1.action="User_Search.aspx";
    }
    Form1.submit();
}
function onFrom()
{
           // var str="";//"<iframe id=\"" + ifFromLoad + "\" frameborder=\"0\" style=\"position: absolute; border: 1px solid #ccc; z-index: 9998;\"></iframe>";
           // str += "<div style=\"filter:Alpha(opacity=50,finishOpacity=0,style=0)\" id=\"" + divFromLoad + "\" style=\"position: absolute; border: 1px solid #ccc; width: 200px; height: 50px; z-index: 9999;\"><table border=\"0\" cellpadding=\"0\" cellspacing=\"0\"><tr><td valign=\"middle\"><img width=\"32px\" height=\"32\"  /><span class=\"red_num\">" + strLoad + "</span><a href=\"#\" onclick=\"location.reload();\">"+ Refresh +"</a></td></tr></table></div>";
           // str="<div id=\"divFromLoad\" style=\"position:absolute;visibility:hidden; FILTER: alpha(opacity=75);left:0px; top:0px; width:255px; height:175px; z-index:10000; background-color: #66CC33; layer-background-color: #66CC33; border: 1px none #000000;\">";
            //document.write(str);
            document.getElementById(ifFromLoad).style.visibility="visible";
            document.getElementById(ifFromLoad).style.width = window.screen.availWidth + "px";
            document.getElementById(ifFromLoad).style.height = window.screen.availHeight + 500 + "px";
            document.getElementById(ifFromLoad).style.filter = "alpha(opacity=80)";
            document.getElementById(divFromLoad).style.visibility="visible";
            document.getElementById(divFromLoad).style.left = ((window.screen.width/2)-10) + "px";
            document.getElementById(divFromLoad).style.top = ((window.screen.height/2)-150) + "px";
            //document.getElementById(divFromLoad).style.filter = "alpha(opacity=50)";
}
function Show()
{
    onFrom();
    SelectIndex();
}
function IndustryselectI(id,name)
{
	var k=0;
	try
        {
        for(var i=0;i<Industryliststemp.length;i++)
        {
            for(var j=0;j<Industryliststemp[i].length;j++)
            {
                if(Industryliststemp[i][j]==id)
                {
                    Industryliststemp.remove(Industryliststemp[i]);
                    k++;
                }
            }
        }
        }
        catch(o){}
	IndustryHTMLG();
	if(k>0)
    	ClearCheckBox(name,"div1");
}
function IndustryHTMLG()
{
    document.getElementById("Industrylist").innerHTML=IndustryHTMLG(1);
    //<span><input type=\"checkbox\" onclick=\"IndustryselectI('"+s[0]+"','"+s[1]+"');\" name=\""+s[0]+"\" id=\""+s[0]+"\" value=\""+s[1]+"\" att=\""+s[1]+"\" />"+s[0]+"</span>
}
function IndustryHTMLG(o)
{
    var str="<div id=\"Industrylist\">";
    for(var i=0;i<Industryliststemp.length;i++)
    {
        str+="<span onclick=\"IndustryselectI('"+Industryliststemp[i][1]+"','"+Industryliststemp[i][0]+"',0);\" onMouseOver=\"this.className='mmmouseover'\" onMouseOut=\"this.className='mmmouseout'\"><input type=\"checkbox\" checked=\"true\" onclick=\"IndustryselectI('"+Industryliststemp[i][1]+"','"+Industryliststemp[i][0]+"',0);\" name=\""+Industryliststemp[i][0]+"\" id=\""+Industryliststemp[i][0]+"\" value=\""+Industryliststemp[i][1]+"\" att=\""+Industryliststemp[i][1]+"\" />"+Industryliststemp[i][0]+"</span>&nbsp;&nbsp;&nbsp;&nbsp;<br>"
    }
    str+="</div>";
    if(jobliststemp.length==0)
        str="<div id=\"postlist\"></div>";
    return str;
}
function SelectIndex()
{
    for(var i=0;i<data.length;i++)
    {
        Excute(data[i],i);
    }
}
function CheckIf()
{
    var k=0;
    var Check=document.getElementById("divFromLoad");
    for(var j=0;j<Check.all.length;j++)
    {
        
        if(Check.all[j].type=="checkbox"&&Check.all[j].tagName=="INPUT"&&Check.all[j].checked==true)
        {
            k++;
        }
    }
    if(k>10)
    {
        alert("只能有10个条件");
        return false;
    }
    return true;
}
function ESpecialityItemclick()
{
    document.getElementById(ifFromLoad).style.visibility="visible";
    document.getElementById(ifFromLoad).style.width = window.screen.availWidth + "px";
    document.getElementById(ifFromLoad).style.height = window.screen.availHeight + 500 + "px";
    document.getElementById(ifFromLoad).style.filter = "alpha(opacity=80)";
    document.getElementById("div1").style.visibility="visible";
    document.getElementById("div1").style.left = ((window.screen.width/2)-200) + "px";
    document.getElementById("div1").style.top = ((window.screen.height/2)-250) + "px";
    document.getElementById("div1").style.width="580";
    
    var slist=new Array();
    var g=0;
    for(var h=0;h<arrSpecialityItem.length;h++)
    {
        if(arrSpecialityItem[h]!=null)
        {
            slist[g]=new Array(g+","+arrSpecialityItem[h]+","+arrSpecialityItemId[h]);
            g++;
        }
    }
    var j=slist.length;
    var o=j%4;
    var count=j/4;
    if(o!=0)
    {
        count++;
    }
    var h=0;
    var str="<span class=\"STYLE1\">修改显示字段</span>  &nbsp;&nbsp; 最多选择1个字段*<br /><br />";
    /*
    <table width=\"100%\" border=\"0\" cellpadding=\"0\" cellspacing=\"3\" bgcolor=\"#FFFFFF\" style=\"border:#B26C21 1px solid;\">";
    for(var k=0;k<count;k++)//arrCity arrCityId
    {
          str+="<tr>";
          for(var i=1;i<5;i++)
          {
                try
                {
               var s=slist[h*4+i].toString().split(',');
               if(arrIndustry[h*4+i]==null)
               {
                    str+="<td><span></span></td>";
               }
               else
               {
                    str+="<td><span><input type=\"checkbox\" name=\""+s[1]+"\" id=\""+s[1]+"\" value=\""+s[2]+"\" />"+s[1]+"</span></td>";
               }
               }
               catch(e){}
          }       
          h++;   
          str+="</tr>"  
    }
        str+="<tr>";
  
        str+="<td></td>";
        str+="<td>&nbsp;</td>";
        str+=" <td>&nbsp;</td>";
        str+="<td>&nbsp;</td>";
        str+="</tr>";

        str+="<tr>";
        str+=" <td height=\"10\" colspan=\"4\" valign=\"middle\" background=\"images/regDashed02.gif\" class=\"pc\">&nbsp;</td>";
        str+="</tr>";
        str+="<tr>";
        str+="<td height=\"40\" colspan=\"4\" valign=\"middle\" class=\"pc\"> <input name=\"Submit2\" class=\"hand but01\" type=\"button\" onclick=\"go()\" value=\"确定\" /> <input name=\"Submit2\" class=\"hand but01\" type=\"button\" onclick=\"cancle('div1')\" value=\"取消\" /></td>";
        str+="</tr>";
        str+="<tr>   "; 
        str+="</table>";
        */
       str+="<table width=\"100%\" border=\"0\" cellpadding=\"0\" cellspacing=\"3\" bgcolor=\"#FFFFFF\" style=\"border:#B26C21 1px solid;\">";
        str+="<tr>";
        str+="<td height=\"28\">请您选择专业类别";
        str+="<select name=\"sel_SpecialityType\" id=\"sel_SpecialityType\" onchange=\"setItem(this.value)\">";
        str+="</select>";
        str+="</td>";
        str+="</tr>";
        str+="<tr>";
        str+=" <td class=\"dot-line\"><ul class=\"floatUl\" id=\"SpecialityItem\">";
	    str+="<div style=\"clear:both\"></div>";
	    str+="</ul>";
	    str+="</td>";
        str+="</tr>";
        str+=" <tr>";
        str+="<td class=\"pc dot-line\">";
        str+="<br /><input type=\"button\" class=\"but01 hand\" value=\"确定\" onclick=\"setValue();\"/>&nbsp;&nbsp;<input type=\"button\" class=\"but01 hand\" value=\"取消\" onclick=\"cancle('div1')\"/>";
        str+="</td>";
        str+="</tr>";
        str+="</table>";
        document.getElementById("div1").innerHTML=str;
        setType();
        setItem(1);
}
function setValue()
{
    var obj = document.getElementsByTagName("input");
    for(var i = 0;i < obj.length; i++)
    {
        if(obj[i].type == "radio" && obj[i].checked == true)
        {
            document.getElementById("SpecialityItemk").value = document.getElementById("rad_ItemText"+obj[i].value).innerHTML;
            document.getElementById("professionals").value = obj[i].value;
            profe=document.getElementById("rad_ItemText"+obj[i].value).innerHTML;
        }
    }
    //setSelectDisplay("");
    document.getElementById("SpecialityItem").focus();
    cancle('div1');
}
function JobItemclick()
{
/*
    try
    {
        
        if(joblists.length>0)
        {
            document.getElementById(ifFromLoad).style.visibility="visible";
            document.getElementById(ifFromLoad).style.width = window.screen.availWidth + "px";
            document.getElementById(ifFromLoad).style.height = window.screen.availHeight + 500 + "px";
            document.getElementById(ifFromLoad).style.filter = "alpha(opacity=80)";
            document.getElementById("divz").style.visibility="visible";
            document.getElementById("divz").style.left = ((window.screen.width/2)-200) + "px";
            document.getElementById("divz").style.top = ((window.screen.height/2)-250) + "px";
            document.getElementById("divz").style.width="480";
            return;
        }
    }
    catch(o){}
*/
    document.getElementById(ifFromLoad).style.visibility="visible";
    document.getElementById(ifFromLoad).style.width = window.screen.availWidth + "px";
    document.getElementById(ifFromLoad).style.height = window.screen.availHeight + 500 + "px";
    document.getElementById(ifFromLoad).style.filter = "alpha(opacity=80)";
    document.getElementById("divz").style.visibility="visible";
    document.getElementById("divz").style.left = ((window.screen.width/2)-200) + "px";
    document.getElementById("divz").style.top = ((window.screen.height/2)-250) + "px";
jobliststemp = new Array();
	for(var i=0;i<joblists.length;i++)
	{
		jobliststemp[i]=new Array(joblists[i][0].toString(),joblists[i][1].toString());
		//new[(joblists.length)]=new Array(id,name);
	}
    document.getElementById("divz").style.width="480";
    SelectJobL();
    	
}
function SelectJobL()
{
    var slist=new Array();
    var g=0;
    for(var h=0;h<arrJobItem.length;h++)
    {
        if(arrJobItem[h]!=null)
        {
            slist[g]=new Array(arrJobItem[h]+","+arrJobItemId[h]);
            g++;
        }
    }
    var j=slist.length;
    var o=j%4;
    var count=j/4;
    if(o!=0)
    {
        count++;
    }
    var h=0;
    var p=0;
    var o=0;
    var str="<span class=\"STYLE1\">修改显示字段</span>  &nbsp;&nbsp; 最多选择3个字段*<br /><br /><table width=\"100%\" border=\"0\" cellpadding=\"0\" cellspacing=\"3\" bgcolor=\"#FFFFFF\" style=\"border:#B26C21 1px solid;\">";
    for(var k=1;k<count;k++)//arrCity arrCityId
    {
          str+="<tr>";
          for(var i=1;i<5;i++)
          {
                try
                {
                var s=slist[h*4+i].toString().split(',');
                str+="<td class=\"hand\" onMouseOver=\"this.className='mmmouseover'\" onMouseOut=\"this.className='mmmouseout'\"><input class=\"hand\" type=\"checkbox\" onclick=\"jobselectL('"+s[0]+"','"+s[1]+"');\" name=\""+s[0]+"\" id=\""+s[0]+"\" value=\""+s[1]+"\" att=\""+s[1]+"\" /><span class=\"hand\" onclick=\"jobselectL('"+s[0]+"','"+s[1]+"',0);\" >"+s[0]+black(s[0].toString())+"</span></td>";
		
                }
                catch(e){}
                //p=Add(h*4+i);
                 /*
                if(h*4+i==16||h*4+i==29||h*4+i==36)
                {
                    p=h*4+i+1;
                    o++;
                    str+="<td><span><input type=\"checkbox\" name=\""+arrJobItem[p]+"\" id=\""+arrJobItem[p]+"\" value=\""+arrJobItemId[p]+"\" />"+arrJobItem[p]+"</span></td>";
                }
                else
                {
                    p=h*4+i+o;
                    
                    str+="<td><span><input type=\"checkbox\" name=\""+arrJobItem[p]+"\" id=\""+arrJobItem[p]+"\" value=\""+arrJobItemId[p]+"\" />"+arrJobItem[p]+"</span></td>";
                }
                //alert(p);
                //if(p)
                if(p!=null)
                {
                    //str+="<td><span><input type=\"checkbox\" name=\""+arrJobItem[p]+"\" id=\""+arrJobItem[p]+"\" value=\""+arrJobItemId[p]+"\" />"+arrJobItem[p]+"</span></td>";
                }
              
               if(arrJobItem[h*4+i]==null)
               {
                    p=Add(h*4+i);
                    alert(arrJobItem[h*4+i+p]);
                    str+="<td><span><input type=\"checkbox\" name=\""+arrJobItem[h*4+i+p]+"\" id=\""+arrJobItem[h*4+i+p]+"\" value=\""+arrJobItemId[h*4+i+p]+"\" />"+arrJobItem[h*4+i+p]+"</span></td>";
                    //str+="<td><span></span></td>";
                    p++;
               }
               else
               {
                    str+="<td><span><input type=\"checkbox\" name=\""+arrJobItem[h*4+i+p]+"\" id=\""+arrJobItem[h*4+i+p]+"\" value=\""+arrJobItemId[h*4+i+p]+"\" />"+arrJobItem[h*4+i+p]+"</span></td>";
               }
               */
          }       
          h++;   
          str+="</tr>"  
    }
    str+="<tr>";

    str+="<td></td>";
    str+="<td>&nbsp;</td>";
    str+=" <td>&nbsp;</td>";
    str+="<td>&nbsp;</td>";
    str+="</tr>";
    str+="<tr>";
    str+=" <td height=\"10\" colspan=\"4\" valign=\"middle\" background=\"images/regDashed02.gif\" class=\"pc\">&nbsp;</td>";
    str+="</tr>";
    str+="<tr>";
    str+=" <td colspan=\"4\">您选择的有：<br><div id=\"joblist\"></div></td>";
    str+="</tr>";
    str+="<tr>";
    str+=" <td height=\"10\" colspan=\"4\" valign=\"middle\" background=\"images/regDashed02.gif\" class=\"pc\">&nbsp;</td>";
    str+="</tr>";
    str+="<tr>";
    str+="<td height=\"40\" colspan=\"4\" valign=\"middle\" class=\"pc\"> <input name=\"Submit2\" class=\"hand but01\" type=\"button\" onclick=\"go(1)\" value=\"确定\" /> <input name=\"Submit2\" class=\"hand but01\" type=\"button\" onclick=\"cancle('divz')\" value=\"取消\" /></td>";
    str+="</tr>";
    str+="<tr>   "; 
    str+="</table>";
    /*
    if(window.navigator.userAgent.indexOf("MSIE")>=1)
    {
        document.getElementById("divz").outerHTML=str;
    }
    else
    {
        document.getElementById("divz").innerHTML=str;
    }
    */
    hiddenselect();
    try
    {
    document.getElementById("divz").innerHTML=str;
    FillBox("divz",1);
    }
    catch(o){}
}
function showselect()
{
    try
    {
        document.getElementById("AddTime").style.display="";
        document.getElementById("WorkYear").style.display="";
        document.getElementById("Salary").style.display="";
        document.getElementById("CompanyType").style.display="";
        document.getElementById("Degree").style.display="";
        document.getElementById("WorkType").style.display="";  
        document.getElementById("postnum").style.display="";
        document.getElementById("SendCycle").style.display="";
    }
    catch(o){}
}
function hiddenselect()
{
    try
    {
        document.getElementById("AddTime").style.display="none";
        document.getElementById("WorkYear").style.display="none";
        document.getElementById("Salary").style.display="none";
        document.getElementById("CompanyType").style.display="none";
        document.getElementById("Degree").style.display="none";
        document.getElementById("WorkType").style.display="none";
        document.getElementById("postnum").style.display="none";
        document.getElementById("SendCycle").style.display="none";
    }
    catch(o){}
}
function FillBox(o,p)
{
	var j=document.getElementById(o).getElementsByTagName("INPUT");
	if(p==1)
	{
	for(var i=0;i<joblists.length;i++)
	{
		for(var k=0;k<j.length;k++)
		{
			if(j[k].name==joblists[i][0])
			{
				j[k].checked=true;
			}
		}
	}
	for(var i=0;i<jobliststemp.length;i++)
	{
		jobHTML()
		//jobselectL(joblists[i][0],jobliststemp[i][1]);
	}
	}
	if(p==2)
	{
	for(var i=0;i<Industrylists.length;i++)
	{
		for(var k=0;k<j.length;k++)
		{
			if(j[k].name==Industrylists[i][0])
			{
				j[k].checked=true;
			}
		}
	}
	for(var i=0;i<Industrylists.length;i++)
	{
		IndustryHTML()
		//jobselectL(joblists[i][0],joblists[i][1]);
	}
	}
}
function Add(i)
{
    if(arrJobItem[i]==null)
    {
        i=i+1;
        Add(i);
    }
    else
    {
        return i;
    }
}
function Educlick()
{
    document.getElementById(ifFromLoad).style.visibility="visible";
    document.getElementById(ifFromLoad).style.width = window.screen.availWidth + "px";
    document.getElementById(ifFromLoad).style.height = window.screen.availHeight + 500 + "px";
    document.getElementById(ifFromLoad).style.filter = "alpha(opacity=80)";
    document.getElementById("div1").style.visibility="visible";
    document.getElementById("div1").style.left = ((window.screen.width/2)-200) + "px";
    document.getElementById("div1").style.top = ((window.screen.height/2)-250) + "px";
    document.getElementById("div1").style.width="280";
    var str="<span class=\"STYLE1\">修改显示字段</span>  &nbsp;&nbsp; 请输入学历<br /><br /><table width=\"100%\" border=\"0\" cellpadding=\"0\" cellspacing=\"3\" bgcolor=\"#FFFFFF\" style=\"border:#B26C21 1px solid;\">";
    str+="<td valign=\"middle\" class=\"pc\"><br><span><select name=\"Degree1\" id=\"Degree1\" style=\"width:80px;\">";
            str+="<option value=\"99\">不限</option>";
            str+="<option value=\"1\">初中</option>";
            str+="<option value=\"2\">高中</option>";
            str+="<option value=\"3\">中技</option>";
            str+="<option value=\"4\">中专</option>";
            str+="<option value=\"5\">大专</option>";
            str+="<option value=\"6\">本科</option>";
            str+="<option value=\"7\">硕士</option>";
            str+="<option value=\"8\">博士</option>";
            str+="<option value=\"9\">其他</option>";
            str+="</select>";
            str+="&nbsp; 至 &nbsp;";
            str+="<select name=\"Degree2\" id=\"Degree2\" style=\"width:80px;\">";
            str+="<option value=\"99\">不限</option>";
            str+="<option value=\"1\">初中</option>";
            str+="<option value=\"2\">高中</option>";
            str+="<option value=\"3\">中技</option>";
            str+="<option value=\"4\">中专</option>";
            str+="<option value=\"5\">大专</option>";
            str+="<option value=\"6\">本科</option>";
            str+="<option value=\"7\">硕士</option>";
            str+="<option value=\"8\">博士</option>";
            str+="<option value=\"9\">其他</option>";
            str+="</select>";
            str+="</span></td>";
    str+="<tr>";
    str+="   <td height=\"10\" colspan=\"4\" valign=\"middle\" background=\"images/regDashed02.gif\" class=\"pc\">&nbsp;</td>";
    str+="</tr>";
    str+="<tr>";
        str+="<td height=\"40\" colspan=\"4\" valign=\"middle\" class=\"pc\"> <input name=\"Submit2\" class=\"hand but01\" type=\"button\" onclick=\"go(4)\" value=\"确定\" /> <input name=\"Submit2\" class=\"hand but01\" type=\"button\" onclick=\"cancle('div1')\" value=\"取消\" /></td>";
        str+="</tr>";
        str+="<tr>   "; 
        str+="</table>";
        document.getElementById("div1").innerHTML=str;
}
function ageclick()
{
    document.getElementById(ifFromLoad).style.visibility="visible";
    document.getElementById(ifFromLoad).style.width = window.screen.availWidth + "px";
    document.getElementById(ifFromLoad).style.height = window.screen.availHeight + 500 + "px";
    document.getElementById(ifFromLoad).style.filter = "alpha(opacity=80)";
    document.getElementById("div1").style.visibility="visible";
    document.getElementById("div1").style.left = ((window.screen.width/2)-200) + "px";
    document.getElementById("div1").style.top = ((window.screen.height/2)-250) + "px";
    document.getElementById("div1").style.width="280";
    var str="<span class=\"STYLE1\">修改显示字段</span>  &nbsp;&nbsp; 请输入年龄<br /><br /><table width=\"100%\" border=\"0\" cellpadding=\"0\" cellspacing=\"3\" bgcolor=\"#FFFFFF\" style=\"border:#B26C21 1px solid;\">";
    str+="<td valign=\"middle\" class=\"pc\"><br><span><input id=\"age1\" name=\"age1\" type=\"text\" style=\"width:40px;\" />&nbsp; 至 &nbsp;<input id=\"age2\" name=\"age2\" type=\"text\" style=\"width:40px;\" /></span></td>";
    str+="<tr>";
    str+="   <td height=\"10\" colspan=\"4\" valign=\"middle\" background=\"images/regDashed02.gif\" class=\"pc\">&nbsp;</td>";
    str+="</tr>";
    str+="<tr>";
        str+="<td height=\"40\" colspan=\"4\" valign=\"middle\" class=\"pc\"> <input name=\"Submit2\" class=\"hand but01\" type=\"button\" onclick=\"go(3)\" value=\"确定\" /> <input name=\"Submit2\" class=\"hand but01\" type=\"button\" onclick=\"cancle('div1')\" value=\"取消\" /></td>";
        str+="</tr>";
        str+="<tr>   "; 
        str+="</table>";
        document.getElementById("div1").innerHTML=str;
}
/*
function Assignment()
{
	Array newArray= new Array();
	for(var i=0;i<Industrylists.length;i++)
	{
		newArray[i]=new Array(Industrylists[i][0],Industrylists[i][1]);
		//new[(joblists.length)]=new Array(id,name);
	}
	return newArray;
}
*/
function black(o)
{
	var k=16;
	var str="";
	for(var i=0;i<(k-(o.length*2));i++)
	{
		str+="&nbsp;";
	}
	
	return str;
}
function Dclick()
{
    document.getElementById(ifFromLoad).style.visibility="visible";
    document.getElementById(ifFromLoad).style.width = window.screen.availWidth + "px";
    document.getElementById(ifFromLoad).style.height = window.screen.availHeight + 500 + "px";
    document.getElementById(ifFromLoad).style.filter = "alpha(opacity=80)";
    document.getElementById("div1").style.visibility="visible";
    document.getElementById("div1").style.left = ((window.screen.width/2)-200) + "px";
    document.getElementById("div1").style.top = ((window.screen.height/2)-250) + "px";
    document.getElementById("div1").style.width="480";

    //Industryliststemp=Assignment();
	Industryliststemp = new Array();
	for(var i=0;i<Industrylists.length;i++)
	{
		Industryliststemp[i]=new Array(Industrylists[i][0].toString(),Industrylists[i][1].toString());
		//new[(joblists.length)]=new Array(id,name);
	}
    
    var j=41;
    var o=j%4;
    var count=j/4;
    if(o!=0)
    {
        count++;
    }
    var h=0;
    var str="<span class=\"STYLE1\">修改显示字段</span>  &nbsp;&nbsp; 最多选择3个字段*<br /><br /><table width=\"100%\" border=\"0\" cellpadding=\"0\" cellspacing=\"3\" bgcolor=\"#FFFFFF\" style=\"border:#B26C21 1px solid;\">";
    for(var k=1;k<count;k++)//arrCity arrCityId
    {
          str+="<tr>";
          for(var i=1;i<5;i++)
          {
               if(arrIndustry[h*4+i]==null)
               {
                    str+="<td><span></span></td>";
               }
               else
               {//"+arrIndustry[h*4+i]+"
                    str+="<td class=\"hand\" onMouseOver=\"this.className='mmmouseover'\" onMouseOut=\"this.className='mmmouseout'\"><input onclick=\"Industryselect('"+arrIndustry[h*4+i]+"','"+arrIndustryId[h*4+i]+"')\" type=\"checkbox\"  name=\""+arrIndustry[h*4+i]+"\" id=\""+arrIndustry[h*4+i]+"\" att=\""+arrIndustryId[h*4+i]+"\" value=\""+arrIndustryId[h*4+i]+"\" /><span onclick=\"Industryselect('"+arrIndustry[h*4+i]+"','"+arrIndustryId[h*4+i]+"',0)\" class=\"hand\"  >"+arrIndustry[h*4+i]+black(arrIndustry[h*4+i].toString())+"</span></td>";
               }
          }       
          h++;   
          str+="</tr>"  
    }
        str+="<tr>";
  
        str+="<td></td>";
        str+="<td>&nbsp;</td>";
        str+=" <td>&nbsp;</td>";
        str+="<td>&nbsp;</td>";
        str+="</tr>";
        str+="<tr>";
        str+=" <td height=\"10\" colspan=\"4\" valign=\"middle\" background=\"images/regDashed02.gif\" class=\"pc\">&nbsp;</td>";
        str+="</tr>";
    	str+="<tr>";
    	str+=" <td colspan=\"4\">您选择的有：<br><div id=\"Industrylist\"></div></td>";
    	str+="</tr>";
        str+="<tr>";
        str+=" <td height=\"10\" colspan=\"4\" valign=\"middle\" background=\"images/regDashed02.gif\" class=\"pc\">&nbsp;</td>";
        str+="</tr>";
        str+="<tr>";
        str+="<td height=\"40\" colspan=\"4\" valign=\"middle\" class=\"pc\"> <input name=\"Submit2\" class=\"hand but01\" type=\"button\" onclick=\"go(2)\" value=\"确定\" /> <input name=\"Submit2\" class=\"hand but01\" type=\"button\" onclick=\"cancle('div1')\" value=\"取消\" /></td>";
        str+="</tr>";
        str+="<tr>   "; 
        str+="</table>";
        hiddenselect();
        document.getElementById("div1").innerHTML=str;
	FillBox("div1",2);
}


//<input name="Input3" value="选择/修改" class="buttonstyle" type="button" onclick="bgMask('请选择专业类别','SelectSpecialityItem.aspx?stype=1',4)" />
function jobselect(id,name)
{
	var k=0;
	try
        {
        for(var i=0;i<jobliststemp.length;i++)
        {
            for(var j=0;j<jobliststemp[i].length;j++)
            {
                if(jobliststemp[i][j]==id)
                {
                    jobliststemp.remove(jobliststemp[i]);
                    k++;
                }
            }
        }
        }
        catch(o){}
    if(k==0)
    {
        jobliststemp[(jobliststemp.length)]=new Array(id,name);
    }
    jobHTML();
    if(k>0)
    ClearCheckBox(name,"divz");
}

function RemoveArray(array,attachId) 
{ 
var f=false; 
for(var i=0,n=0;i<array.length;i++) 
{ 
if(array[i]!=attachId) 
{ 
array[n++]=array[i];
}else 
f=true; 
} 
if(f==true) 
array.length =array.length - 1; 
} 

Array.prototype.remove = function (obj) { 
return RemoveArray(this,obj); 
};
function go(o)
{
if(o==1)
{
	joblists=new Array();
	for(var k=0;k<jobliststemp.length;k++)
	{
		joblists[k]=new Array(jobliststemp[k][0].toString(),jobliststemp[k][1].toString());	
	}
    //document.getElementById("postss").value="";
    var obj = document.getElementsByTagName("input");
    for(var i = 0;i < obj.length; i++)
    {
        if(obj[i].type == "checkbox" && obj[i].checked == true&&obj[i].getAttribute("att")!=null)
        {
            //document.getElementById("postsk").value = obj[i].name;
            //document.getElementById("postss").value = obj[i].getAttribute("att");
            //postsk=obj[i].name;
        }
    }
    var s="",v="";
    for(var j=0;j<joblists.length;j++)
    {
        s+=joblists[j][1]+"#";
        v+="<span class=\"hand\" onMouseOver=\"this.className='mmmouseover'\" onMouseOut=\"this.className='mmmouseout'\" onclick=\"jobselectG('"+joblists[j][0]+"','"+joblists[j][1]+"',0);\"><input type=\"checkbox\" checked=\"true\" onclick=\"jobselectG('"+joblists[j][0]+"','"+joblists[j][1]+"',0);\" name=\""+joblists[j][0]+"\" id=\""+joblists[j][0]+"\" value=\""+joblists[j][1]+"\" att=\""+joblists[j][1]+"\" />"+joblists[j][0]+"</span>&nbsp;&nbsp;&nbsp;&nbsp;<br>"//+",";
    }
	
    //document.getElementById("postsk").value =v.substring(0,s.length-1);
    document.getElementById("postlist").innerHTML=v;
    document.getElementById("postsk").value =s.substring(0,s.length-1);
    //setSelectDisplay("");
    //document.getElementById("postsk").focus();
    showselect();
    cancle('divz');
}
if(o==2)
{
	Industrylists=new Array();
	for(var k=0;k<Industryliststemp.length;k++)
	{
		Industrylists[k]=new Array(Industryliststemp[k][0].toString(),Industryliststemp[k][1].toString());	
	}
    var obj = document.getElementsByTagName("input");
    for(var i = 0;i < obj.length; i++)
    {
        if(obj[i].type == "radio" && obj[i].checked == true&&obj[i].getAttribute("att")!=null)
        {
            //document.getElementById("Industryy").value = obj[i].id;
           //document.getElementById("Industrys").value = obj[i].getAttribute("att");
            //Industryk=obj[i].name;
        }
    }
    var s="",v="";
    for(var j=0;j<Industrylists.length;j++)
    {
        s+=Industrylists[j][1]+"#";
        v+="<span class=\"hand\" onMouseOver=\"this.className='mmmouseover'\" onMouseOut=\"this.className='mmmouseout'\" onclick=\"IndustryselectI('"+Industrylists[j][0]+"','"+Industrylists[j][1]+"',0);\"><input type=\"checkbox\" checked=\"true\" onclick=\"IndustryselectI('"+Industrylists[j][0]+"','"+Industrylists[j][1]+"',0);\" name=\""+Industrylists[j][0]+"\" id=\""+Industrylists[j][0]+"\" value=\""+Industrylists[j][1]+"\" att=\""+Industrylists[j][1]+"\" />"+Industrylists[j][0]+"</span>&nbsp;&nbsp;&nbsp;&nbsp;<br>"//+",";
    }
    
    //setSelectDisplay("");
    //document.getElementById("postsk").focus();
	//alert(document.getElementById("Industrylist").innerHTML);
    document.getElementById("Industrylistt").innerHTML=v;
    document.getElementById("Industry").value =s.substring(0,s.length-1);
    showselect();
    cancle('div1');
}
if(o==3)
{
    document.getElementById("agek").value = document.getElementById("age1").value+" 至 "+document.getElementById("age2").value
    document.getElementById("ages").value = document.getElementById("age1").value+"*"+document.getElementById("age2").value
    agek=document.getElementById("age1").value+" 至 "+document.getElementById("age2").value
    cancle('div1');
}
if(o==4)
{
    Degrees=document.getElementById("tDegrees").value = document.getElementById("Degree1").value+"*"+document.getElementById("Degree2").value;
    document.getElementById("Degreesk").value = document.getElementById("Degree1").options[document.getElementById("Degree1").selectedIndex].text+" 至 "+document.getElementById("Degree2").options[document.getElementById("Degree2").selectedIndex].text;
    document.getElementById("tDegrees").value = document.getElementById("Degree1").value+"*"+document.getElementById("Degree2").value;
    Degreesk=document.getElementById("Degree1").options[document.getElementById("Degree1").selectedIndex].text+" 至 "+document.getElementById("Degree2").options[document.getElementById("Degree2").selectedIndex].text;
    cancle('div1');
}
if(o==10)
{
    if(!CheckIf())
        return ;
    data=new Array();
    dataname=new Array();
    var l=0;
    var Changediv=document.getElementById("Change");
    var Check=document.getElementById("divFromLoad");
    var str="<table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\">";
    str+="     <tr>";
    str+="        <td height=\"35\">&nbsp;</td>";
    str+="        <td colspan=\"3\">以下是常用的查询条件，点击此按钮可以更改查询条件，最多可选<span class=\"red1\"><strong>10</strong></span>项！";
    str+="          <input name=\"Submit\" type=\"button\" class=\"buttonstyle hand\" onclick=\"Show()\" value=\"更改查询条件\" /></td>";
    str+="        </tr>";
    str+="<tr>";
    str+="<td width=\"8%\" height=\"\"></td>";
    str+="<td width=\"8%\"></td>";
    str+="<td width=\"23%\">";
    str+="</td>";
    str+="<td></td>";
    str+="</tr>";
    for(var j=0;j<Check.all.length;j++)
    {
        //AREA WORKYEAR Degree posts age Industry professional sex WorkLocus LanguageName LaborageMonth LaborageYear LanguageID LastUpdateTime product Market keyword
        if(Check.all[j].type=="checkbox"&&Check.all[j].name=="AREA"&&Check.all[j].tagName=="INPUT"&&Check.all[j].checked==true)
        {
            
            data[l]=0;
            dataname[l]=Check.all[j].value;
            l++;
            var   select_node=document.createElement("select");
            select_node.name="AREAs";
            
            select_node.onchange="SAREA()";
            select_node.id="AREAs";
            for(var k=1;k<36;k++)//arrCity arrCityId
            {
                for(var i=0;i<arrCity[k].length;i++)
                {
                    var opt = new Option(arrCity[k][i],arrCityId[k][i]);
                    select_node.options.add(opt);
                }
                //var opt = new Option(arrCity[k],arrCityId[k]);
                //select_node.options.add(opt);
                
            }
            str+="<tr>";
            str+="<td height=\"30\">&nbsp;</td>";
            str+="<td >目前居住地</td>";
            str+="<td >";
            str+=select_node.innerHTML;
            str+="</td>";
            str+="<td>&nbsp;</td>";
            str+="</tr>";
            
        }
        if(Check.all[j].type=="checkbox"&&Check.all[j].name=="WORKYEAR"&&Check.all[j].tagName=="INPUT"&&Check.all[j].checked==true)
        {
           //WORKYEAR Degree posts age Industry professional sex WorkLocus LanguageName LaborageMonth LaborageYear LanguageID LastUpdateTime product Market keyword
            data[l]=1;
            dataname[l]=Check.all[j].value;
             l++;
            var   select_node=document.createElement("select");
            select_node.name="WORKYEARs";
            select_node.onchange="fWORKYEARs()";
            
            select_node.id="WORKYEARs";
            for(var k=0;k<8;k++)//arrCity arrCityId
            {
                var opt = new Option(arrWorkYear[k],arrWorkYearId[k]);
                select_node.options.add(opt);
                
            }
            str+="<tr>";
            str+="<td height=\"30\">&nbsp;</td>";
            str+="<td>工作年限</td>";
            str+="<td>";
            str+=select_node.innerHTML;
            str+="</td>";
            str+="<td>&nbsp;</td>";
            str+="</tr>";
        }
        if(Check.all[j].type=="checkbox"&&Check.all[j].name=="Degree"&&Check.all[j].tagName=="INPUT"&&Check.all[j].checked==true)
        {
            //Degree posts age Industry professional sex WorkLocus LanguageName LaborageMonth LaborageYear LanguageID LastUpdateTime product Market keyword
            data[l]=2;
            dataname[l]=Check.all[j].value;
            l++;
            str+=" <tr>";
            str+=" <td height=\"30\">&nbsp;</td>";
            str+="<td>学历</td>";
            str+="<td><input id=\"Degreesk\" name=\"Degreesk\" type=\"text\" disabled=\"disable\" style=\"width:204px;\" /></td>";//disabled=\"disable\"
            str+="<td><input name=\"Submit3\" onclick=\"Educlick()\"  type=\"button\" class=\"hand buttonstyle hand\"  value=\"选择/修改\" /></td>";
            str+="</tr>";
        }
        if(Check.all[j].type=="checkbox"&&Check.all[j].name=="posts"&&Check.all[j].tagName=="INPUT"&&Check.all[j].checked==true)
        {
            data[l]=3;
            dataname[l]=Check.all[j].value;
            l++;
            str+="<tr>";
            str+="<td height=\"30\">&nbsp;</td>";
            str+="<td>职能</td>";
            str+="<td><input name=\"postsk\" id=\"postsk\" type=\"text\" disabled=\"disable\" style=\"width:204px;\" /></td>";
            str+="<td><input name=\"Submit3\" onclick=\"JobItemclick()\" type=\"button\" class=\"hand buttonstyle hand\" value=\"选择/修改\" /></td>";
            str+="</tr>";
        }
        if(Check.all[j].type=="checkbox"&&Check.all[j].name=="age"&&Check.all[j].tagName=="INPUT"&&Check.all[j].checked==true)
        {
            data[l]=4;
            dataname[l]=Check.all[j].value;
            l++;
            str+=" <tr>";
            str+="<td height=\"30\">&nbsp;</td>";
            str+="<td>年龄</td>";
            str+="<td><input id=\"agek\" name=\"agek\" type=\"text\" disabled=\"disable\" style=\"width:204px;\" /></td>";
            str+="<td><input name=\"Submit3\" onclick=\"ageclick()\" type=\"button\" class=\"hand buttonstyle hand\" value=\"选择/修改\" /></td>";
            str+="</tr>";
        }
        if(Check.all[j].type=="checkbox"&&Check.all[j].name=="Industry"&&Check.all[j].tagName=="INPUT"&&Check.all[j].checked==true)
        {
            data[l]=5;
            dataname[l]=Check.all[j].value;
            l++;
            str+="<tr>";
            str+="<td height=\"30\">&nbsp;</td>";
            str+="<td>行业</td>";
            str+="<td><input id=\"Industryy\" name=\"Industryy\" type=\"text\" disabled=\"disable\" style=\"width:204px;\" /></td>";
            str+="<td><input name=\"Submit3\" onclick=\"Dclick()\" type=\"button\" class=\"buttonstyle hand\" value=\"选择/修改\" /></td>";
            str+="</tr>";
        }
        if(Check.all[j].type=="checkbox"&&Check.all[j].name=="professional"&&Check.all[j].tagName=="INPUT"&&Check.all[j].checked==true)
        {
            data[l]=6;
            dataname[l]=Check.all[j].value;
            l++;
            str+="<tr>";
            str+="<td height=\"30\">&nbsp;</td>";
            str+="<td>专业</td>";
            str+="<td><input name=\"SpecialityItemk\" id=\"SpecialityItemk\" type=\"text\" disabled=\"disable\" style=\"width:204px;\" /></td>";
            str+="<td><input name=\"Submit3\" onclick=\"ESpecialityItemclick()\" type=\"button\" class=\"hand buttonstyle\"  value=\"选择/修改\" /></td>";
            str+="</tr>";
        }
        if(Check.all[j].type=="checkbox"&&Check.all[j].name=="sex"&&Check.all[j].tagName=="INPUT"&&Check.all[j].checked==true)
        {
            data[l]=7;
            dataname[l]=Check.all[j].value;
            l++;
            str+="<tr>";
            str+="<td height=\"30\">&nbsp;</td>";
            str+="<td>性别</td>";
            str+="<td><select name=\"sexs\" id=\"sexs\" onchange=\"fsex()\" style=\"width:210px;\">";
            str+="<option value=\"99\">不限</option>";
            str+="<option value=\"1\">男</option>";
            str+="<option value=\"2\">女</option>";
            str+="</select></td>";
            str+="<td>&nbsp;</td>";
		    str+="</tr>";
        }
        if(Check.all[j].type=="checkbox"&&Check.all[j].name=="WorkLocus"&&Check.all[j].tagName=="INPUT"&&Check.all[j].checked==true)
        {
            data[l]=8;
            dataname[l]=Check.all[j].value;
            l++;
            var   select_node=document.createElement("select");
            select_node.name="WorkLocusS";
            select_node.id="WorkLocusS";
            for(var k=0;k<35;k++)//arrCity arrCityId
            {
                var opt = new Option(arrProvince[k],arrProvinceId[k]);
                select_node.options.add(opt);
            }
            str+="<tr>";
            str+="<td width=\"8%\" height=\"30\">&nbsp;</td>";
            str+="<td width=\"8%\">户口</td>";
            str+="<td width=\"23%\">";
            str+=select_node.innerHTML;
            str+="</td>";
            str+="<td>&nbsp;</td>";
            str+="</tr>";
        }//           
        if(Check.all[j].type=="checkbox"&&Check.all[j].name=="LanguageName"&&Check.all[j].tagName=="INPUT"&&Check.all[j].checked==true)
        {
            data[l]=9;
            dataname[l]=Check.all[j].value;
            l++;
            str+="<tr>";
            str+="<td height=\"30\">&nbsp;</td>";
            str+="<td>外语</td>";
            str+="<td><select name=\"LanguageNames\" id=\"LanguageNames\" style=\"width:210px;\">";
            str+="<option value=\"99\">不限</option>";
            str+="<option value=\"01\">英语</option>";
            str+="<option value=\"10\">汉语</option>";
            str+="<option value=\"02\">日语</option>";
            str+="<option value=\"03\">法语</option>";
            str+="<option value=\"04\">德语</option>";
            str+="<option value=\"05\">俄语</option>";
            str+="<option value=\"06\">西班牙语</option>";
            str+="<option value=\"07\">朝鲜语</option>";
            str+="<option value=\"08\">阿拉伯语</option>";
            str+="<option value=\"09\">其它</option>";
            str+="</select></td>";
            str+="<td>&nbsp;</td>";
		    str+="</tr>";
        }
        if(Check.all[j].type=="checkbox"&&Check.all[j].name=="LaborageMonth"&&Check.all[j].tagName=="INPUT"&&Check.all[j].checked==true)
        {
            data[l]=10;
            dataname[l]=Check.all[j].value;
            l++;
            str+="<tr>";
            str+="<td height=\"30\">&nbsp;</td>";
            str+="<td>目前薪水</td>";
            str+="<td><select name=\"LaborageMonths\" id=\"LaborageMonths\" style=\"width:210px;\">";
            str+=" <option value=\"\">--请选择--</option>";
            str+="  <option value=\"00\">面议 </option>";
            str+=" <option value=\"01\">1500以下 </option>";
            str+="  <option value=\"02\">1500-1999 </option>";
            str+="  <option value=\"03\">2000-2999 </option>";
            str+="  <option value=\"04\">3000-4499 </option>";
            str+="  <option value=\"05\">4500-5999 </option>";
            str+="  <option value=\"06\">6000-7999 </option>";
            str+="  <option value=\"07\">8000-9999 </option>";
            str+="  <option value=\"08\">10000-14999 </option>";
            str+="  <option value=\"09\">15000-19999 </option>";
            str+="  <option value=\"10\">20000-29999 </option>";
            str+="  <option value=\"11\">30000-49999 </option>";
            str+="  <option value=\"12\">50000及以上 </option>";
            str+="</select></td>";
            str+="<td>&nbsp;</td>";
		    str+="</tr>";
        }
        if(Check.all[j].type=="checkbox"&&Check.all[j].name=="LaborageYear"&&Check.all[j].tagName=="INPUT"&&Check.all[j].checked==true)
        {
            data[l]=11;
            dataname[l]=Check.all[j].value;
            l++;
            str+="<tr>";
            str+="<td height=\"30\">&nbsp;</td>";
            str+="<td>期望薪水</td>";
            str+="<td><select name=\"LaborageYears\" id=\"LaborageYears\" style=\"width:210px;\">";
            str+=" <option value=\"\">--请选择--</option>";
            str+="  <option value=\"00\">面议 </option>";
            str+=" <option value=\"01\">1500以下 </option>";
            str+="  <option value=\"02\">1500-1999 </option>";
            str+="  <option value=\"03\">2000-2999 </option>";
            str+="  <option value=\"04\">3000-4499 </option>";
            str+="  <option value=\"05\">4500-5999 </option>";
            str+="  <option value=\"06\">6000-7999 </option>";
            str+="  <option value=\"07\">8000-9999 </option>";
            str+="  <option value=\"08\">10000-14999 </option>";
            str+="  <option value=\"09\">15000-19999 </option>";
            str+="  <option value=\"10\">20000-29999 </option>";
            str+="  <option value=\"11\">30000-49999 </option>";
            str+="  <option value=\"12\">50000及以上 </option>";
            str+="</select></td>";
            str+="<td>&nbsp;</td>";
		    str+="</tr>";
        }
        if(Check.all[j].type=="checkbox"&&Check.all[j].name=="LanguageID"&&Check.all[j].tagName=="INPUT"&&Check.all[j].checked==true)
        {
            data[l]=12;
            dataname[l]=Check.all[j].value;
            l++;
            str+="<tr>";
            str+="<td height=\"30\">&nbsp;</td>";
            str+="<td>简历语言</td>";
            str+="<td><select name=\"LanguageIDs\" id=\"LanguageIDs\">";
		    str+="<option value=\"1\">中文</option>";
		    str+="<option value=\"2\">英文</option>";
	        str+="</select></td></tr>";
        }
    }
    str+="<tr>";
    str+="<td height=\"30\">&nbsp;</td>";
    str+="<td>主营产品</td>";
    str+="<td><input name=\"products\" id=\"products\" type=\"text\" style=\"width:204px;\" value=\"adsf\"/></td>";
    str+="<td>&nbsp;</td>";
	str+="</tr>";
	str+="<tr>";
    str+="<td height=\"30\">&nbsp;</td>";
	str+="<td>出口市场</td>";
	str+="<td><input name=\"Markets\" id=\"Markets\" type=\"text\" style=\"width:204px;\" /></td>";
	str+="<td>&nbsp;</td>";
	str+="</tr>";
	str+="<tr>";
    str+="<td height=\"30\">&nbsp;</td>";
    str+="<td>关键字</td>";
    str+="<td><input name=\"keywords\" id=\"keywords\" type=\"text\" style=\"width:204px;\" /></td>";
    str+="<td><select name=\"KEYWORDTYPE\" id=\"KEYWORDTYPE\">";
    str+="<option value=\"1\">工作关键字</option>";
    str+="<option value=\"2\">职务名称</option>";
    str+="<option value=\"4\">自我评价</option>";
    str+="<option value=\"6\">证书</option>";
    str+="<option value=\"7\">公司名称</option>";
    str+="<option value=\"8\">学校名称</option>";
    str+="<option value=\"0\">搜索以上全部</option>";
    str+="</select>";
    str+="&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span class=\"gary\">可在下拉框中选择需要搜索的关键字类型。</span></td>";
    str+="</tr>";
	str+="<tr>";
    str+="<td height=\"30\">&nbsp;</td>";
    str+="<td>简历更新</td>";
    str+="<td><select name=\"LastUpdateTimes\" id=\"LastUpdateTimes\" style=\"width:210px;\">";
    str+="<option value=\"0\">不限</option>";
    str+="<option value=\"1\">一周内</option>";
    str+="<option value=\"2\">两周内</option>";
    str+="<option value=\"3\">一个月内</option>";
    str+="<option selected=\"selected\" value=\"4\">两个月内</option>";
    str+="<option value=\"5\">六个月内</option>";
    str+="<option value=\"2008\">2008年</option>";
    str+="<option value=\"2007\">2007年</option>";
    str+="<option value=\"2006\">2006年</option>";
    str+="</select></td>";
    str+="<td>&nbsp;</td>";
    str+="</tr>";
    str+="<tr>";
    str+="<td colspan=\"4\" background=\"images/regDashed02.gif\">&nbsp;</td>";
    str+="</tr>";
	str+="<tr>";
	str+="<td height=\"50\" colspan=\"4\" class=\"pc\"><input name=\"Submit222\" type=\"button\" class=\"but01\" value=\"查询\" onclick=\"actionsubmit(1)\" /></td>";
	str+="</tr>"; 
    str+="</table>";
    
    Changediv.innerHTML=str;
    document.getElementById(divFromLoad).style.visibility="hidden";
    document.getElementById(ifFromLoad).style.visibility="hidden";
    SetValue1();
    CZ();
}
}
function SetValue1()
{
    try
    {
    document.getElementById("SpecialityItemk").value=profe;
    }
    catch(e){}
    try
    {
    document.getElementById("postsk").value=postsk;
    }
    catch(e){}
    try
    {
    document.getElementById("Industryy").value=Industryk;
    }
    catch(e){}
    try
    {
    document.getElementById("Degreesk").value=Degreesk;
    }
    catch(e){}
    try
    {
    document.getElementById("agek").value=agek;
    }
    catch(e){}
}
function cancle(str)
{
    Clear();
    SelectIndex();
    document.getElementById(str).style.visibility="hidden";
    document.getElementById(ifFromLoad).style.visibility="hidden";
    showselect();
}
function Clear()
{
    try
    {
    document.getElementById("AREA").checked=false;
    document.getElementById("WORKYEAR").checked=false;
    document.getElementById("Degree").checked=false;
    }
    catch(o){}
}
function FillJob()
{
    for(var j=0;j<joblists.length;j++)
    {
        var obj = document.getElementById("divz").getElementsByTagName("input");
        for(var i = 0;i < obj.length; i++)
        {
	    if(obj[i].type == "checkbox" && obj[i].checked == false&&obj[i].getAttribute("att")!=null)
            {
                if(obj[i].getAttribute("att")==joblists[j][1])
                {
		    obj[i].checked=true;
                }
                //document.getElementById("postsk").value = obj[i].name;
                //document.getElementById("postss").value = obj[i].getAttribute("att");
                //postsk=obj[i].name;
            }
        }
    }
}
function CZ()
{
    document.getElementById("products").value=qproducts;
    document.getElementById("Markets").value=qmarkets;
    document.getElementById("keywords").value=keyword;
    try
    {
    document.getElementById("tAREAs").value=area;
    document.getElementById("tWORKYEARs").value=WORKYEARs;
    for(var i=0;i<data.length;i++)
    {
        var j=41;
        id="3";
        
        if(data[i]=="6")
        {
            
            for(var p=0;p<arrItemID.length;p++)
            {
                try
                {
                    for(var l=0;l<arrItemID[p].length;l++)
                    {
                        if(arrItemID[p][l]==dataname[i])
                        {
                            document.getElementById("professionals").value = arrItemID[p][l];
                            document.getElementById("SpecialityItemk").value=arrItem[p][l];
                        }
                    }
                }
                catch(o){}
            }
            
            
            //document.getElementById("Industryy").value=arrIndustry[k];
        }
        for(var k=1;k<j;k++)//arrCity arrCityId
        {
            if(arrIndustryId[k]==dataname[i]&&data[i]=="5")
            {
               
                document.getElementById("Industrys").value = arrIndustryId[k];
                document.getElementById("Industryy").value=arrIndustry[k];
            }
            if(data[i]=="0")
            {
               
                document.getElementById("AREAs").value = dataname[i];
                //document.getElementById("Industryy").value=arrIndustry[k];
            }
            if(data[i]=="1")
            {
               
                document.getElementById("WORKYEARs").value = dataname[i];
                //document.getElementById("Industryy").value=arrIndustry[k];
            }
            if(arrJobItemId[k]==dataname[i]&&data[i]=="3")
            {
               //职能赋值
                document.getElementById("postss").value = arrJobItemId[k];
                document.getElementById("postsk").value=arrJobItem[k];
                joblists[0]=new Array(arrJobItem[k],arrJobItemId[k]);
                jobHTML();
                FillJob();
                //document.getElementById("Industryy").value=arrIndustry[k];
            }
            if(data[i]=="2")
            {
                if(dataname[i]=="undefined")
                {
                    document.getElementById("tDegrees").value = "";
                    document.getElementById("Degreesk").value="";
                }
                else
                {
                    document.getElementById("tDegrees").value = dataname[i];
                    Degreesk=dataname[i];
                    var spiler =dataname[i].split('*');
                    document.getElementById("Degreesk").value=GetDegree(spiler[0])+" 至 "+GetDegree(spiler[1]);
                }
                //document.getElementById("Industryy").value=arrIndustry[k];
            }
            if(data[i]=="4")
            {
                if(dataname[i]=="undefined")
                {
                    document.getElementById("ages").value = "";
                    document.getElementById("agek").value="";
                }
                else
                {
                    document.getElementById("ages").value = dataname[i]; 
                    Degreesk=dataname[i];
                    var spiler =dataname[i].split('*');
                    document.getElementById("agek").value=spiler[0]+" 至 "+spiler[1];
                }
                //document.getElementById("Industryy").value=arrIndustry[k];
            }
            if(data[i]=="7")
            {
                document.getElementById("sexs").value = dataname[i];
                //document.getElementById("Industryy").value=arrIndustry[k];
            }
            if(data[i]=="10")
            {
                document.getElementById("LaborageMonths").value = dataname[i];
                //document.getElementById("Industryy").value=arrIndustry[k];
            }
            
        }
    }
    }
    
    catch(p){}
}
function GetDegree(o)
{
    for(var i=1;i<arrDegreeId.length;i++)
    {
        if(arrDegreeId[i]==o)
        {
            return arrDegree[i];
        }
    }
    return "";
}
function GetAge(o)
{
    for(var i=1;i<arrAgeId.length;i++)
    {
        if(arrAgeId[i]==o)
        {
            return arrAge[i];
        }
    }
    return "";
}
function Excute(k,i)
{
    if(k==0)
    {
        try
        {
        document.getElementById("AREA").checked=true;
        document.getElementById("AREA").value=dataname[i];
        }
        catch(o){}
    }
    if(k==1)
    {
        try
        {
        document.getElementById("WORKYEAR").checked=true;
        document.getElementById("WORKYEAR").value=dataname[i];
        }
        catch(o){}
    }
    if(k==2)//
    {
        try
        {
        document.getElementById("Degree").checked=true;
        document.getElementById("Degree").value=dataname[i];
        }
        catch(o){}
    }
}