📄 res.js
字号:
var issts=true;
var istiao=false;
var lis=new Array(6);
var intlis=0;
var tsid;
lis[0]="basic";
lis[1]="atman";
lis[2]="busioness";
lis[3]="workEx";
lis[4]="school";
lis[5]="language";
var xmlHttp;
var obj;
function createXMLHttpRequest(){
if(window.XMLHttpRequest){ // Mozilla
xmlHttp = new XMLHttpRequest();
}else if (window.ActiveXObject){ // IE
try{
xmlHttp = new ActiveXObject("Msxml2.XMLHTTP");
}catch(e){
try{
xmlHttp = new ActiveXObject("Microsoft.XMLHTTP");
}catch(e){}
}
}
}
function anchor_1(tname,tid){
var divone=document.getElementById(tid);
var os=divone.innerHTML;
if(os.length<20){
if(issts){
createXMLHttpRequest();
xmlHttp.onreadystatechange=loadresume;
xmlHttp.open("Get",tname+"?method=load&type="+tid);
obj=divone;
issts=false;
xmlHttp.send(null);
return;
}
}else{
return;
}
}
function anchor_2(tname,tid){
var divone=document.getElementById(tid);
var os=divone.innerHTML;
if(os.length<20){
if(issts){
createXMLHttpRequest();
xmlHttp.onreadystatechange=loadresume;
xmlHttp.open("Get",tname+"?method=load&type="+tid);
obj=divone;
issts=false;
istiao=true;
tsid=tid;
xmlHttp.send(null);
return;
}
}else{
window.location.href="#a"+tid;
return;
}
}
function anchor_3(tname,tid,tud){
var divone=document.getElementById(tud);
var os=divone.innerHTML;
if(os.length<150){
if(issts){
createXMLHttpRequest();
xmlHttp.onreadystatechange=loadresume;
xmlHttp.open("Get",tname+"?method=load&type="+tid+"&date="+new Date());
obj=divone;
issts=false;
istiao=true;
tsid=tid;
xmlHttp.send(null);
return;
}
}
}
function loadresume(){
if(xmlHttp.readyState==4){
if(xmlHttp.status==200){
var vtext=xmlHttp.responseText;
vtext=vtext.substring(vtext.indexOf("<div>"),vtext.lastIndexOf("</div>"))+"</div>";
obj.innerHTML=xmlHttp.responseText;
issts=true;
if(istiao){
istiao=false;
window.location.href="#a"+tsid;
return;
}
if(intlis<lis.length-1){
intlis++;
if(intlis==3){
anchor_1("../jobExperience.do",lis[intlis]);
return;
}
if(intlis==4){
anchor_1("../schoolSet.do",lis[intlis]);
return;
}
if(intlis==5){
anchor_1("../language.do",lis[intlis]);
return;
}
else{
anchor_1("../resume.do",lis[intlis]);
}
}
}
}
}
sub_1();
function sub_1(){
var forms=document.forms;
if(forms==null){return;}
var resname=document.getElementById("resume.resName");
for(var j=0;j<forms.length;j++)
{
var form1=forms[j].elements;
var where="";
for(var i=0;i<form1.length;i++){
if(form1[i].type!="button"&&form1[i].value.length>1){
if(form1[i].type=="radio"){
if(form1[i].checked==true){
where+="&"+form1[i].name+"="+form1[i].value;
}
}else{
where+="&"+form1[i].name+"="+form1[i].value;
}
}
}
if(where.length>5){
where="method=add"+where;
where+="&"+resname.name+"="+resname.value;
createXMLHttpRequest();
/// xmlHttp.onreadystatechange=chu;
xmlHttp.open("Post",forms[j].action);
xmlHttp.setRequestHeader("content-length",where.length);
xmlHttp.setRequestHeader("Content-Type","application/x-www-form-urlencoded");
xmlHttp.send(where);
}
}
setTimeout("sub_1()",600000);
}
function chu(){}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -