select
https://blog.csdn.net/malz_zh/article/details/112831092
P INPUT
<TD style="WIDTH: 35%" bgColor=#ffffff>
<UL class=token-input-list-facebook jQuery111109417212170793457="14">
<LI class=token-input-token-facebook jQuery111109417212170793457="21">
<P>李鹏</P>
<SPAN class=token-input-delete-token-facebook jQuery111109417212170793457="19">×</SPAN>
</LI>
<LI class=token-input-token-facebook jQuery111109417212170793457="24">
<P>王曦</P>
<SPAN class=token-input-delete-token-facebook jQuery111109417212170793457="22">×</SPAN>
</LI>
<LI class=token-input-input-token-facebook>
<INPUT id=token-input-personName_6318787 style="OUTLINE-WIDTH: medium; OUTLINE-STYLE: none; OUTLINE-COLOR: invert" autocomplete="off" jQuery111109417212170793457="6">
<tester style="FONT-SIZE: 12px; FONT-FAMILY: Verdana; WIDTH: auto; WHITE-SPACE: nowrap; POSITION: absolute; FONT-WEIGHT: 400; LEFT: -9999px; LETTER-SPACING: 0px; TOP: -9999px"></tester>
</LI>
</UL>
<INPUT id=personName_6318787 class=personName style="DISPLAY: none" width="35%" value=,,, name=personName_6318787 jQuery111109417212170793457="11">
</TD>
P INPUT获取值
function saveData(){
var personName = "";
var msg="";
var trs = $("#zi01 tr"); //获取表tr标签中所有值
for(var j=0;j<trs.length;j++){
var loc_personName = trs[j].children[3].innerText;//获取表第i个tr标签中第四个th标签中的值
if(loc_personName==" ") {
alert("请选择人员!");
return;
}
}
var tableObj = document.getElementById("zi01"); //获取表中所有值
for(var i=0;i<tableObj.rows.length;i++){
personName = "";
//获取表第i个tr标签中第2个th标签中的第一个input标签的值
var jobId = tableObj.rows[i].cells[1].getElementsByTagName("input")[0].value;;
var personCode = tableObj.rows[i].cells[3].getElementsByTagName("input")[1].value;
//获取表第i个tr标签中第四个th标签中的所有p标签的值
var personNames = tableObj.rows[i].cells[3].getElementsByTagName("p");
for(var s=0;s<personNames.length;s++){
personName = personName + personNames[s].innerText+",";
}
personName = personName.substr(0, personName.length-1);
var param="personCode="+personCode+"&personName="+personName+"&jobMantainId="+jobId+"&infomationMtName="+'<%=infomationMtName%>'+
'&userName='+'<%=strCnUserName%>'+'&userCode='+'<%=strUserName%>'+'&infomationMtId='+'<%=id%>';
msg=getTestAjaxPost("RYFG.PersonalMantain/editWorkInfo",encodeURI(param));
}
if(msg>0){
alert("修改成功。");
parent.window.location.href=parent.window.location.href;
parent.$.XYTipsWindow.removeBox();
}else if(msg>-2){
alert("修改失败。");
}
}