求人帮我看看这代码哪有问题了!(急)

来源:百度知道 编辑:UC知道 时间:2024/09/22 05:12:14
<TR>
<TD class=ArtWz>
<DIV align=right><FONT color=#646464><FONT style="FONT-SIZE: 12px" face=宋体 size=1>1</FONT></DIV></FONT></TD>
<TD><INPUT id=text10 onkeydown=onlyNumber() onblur=texthide(); style="FONT-SIZE: 12px; WIDTH: 99px; HEIGHT: 20px" onfocus="textshow(this,’<FONT size=2>请填写1</FONT>’);" maxLength=100 name=txt1></TD></TR>
<SCRIPT language=javascript>
function textshow(e,words) {
var t=e.offsetTop;
var l=e.offsetLeft;
while(e=e.offsetParent){
l+=e.offsetLeft;
t+=e.offsetTop;
}
alt1.style.position="absolute";
alt1.style.top=t;
alt1.style.left=l+130; //距离控件左侧位置200
altword.innerHTML=words;
alt1.style.display="";
}
function texthide(){
alt1.style.display="none

alt1 是什么,,没定义啊,altword.这个是什么

我想你是这个意思把,大致改了一下,,其他的你自己可以加上去 ,如果有乱吗,就把字符集再设置一下,
<TR>
<TD class=ArtWz>
<DIV align=right id="altword">
<FONT style="FONT-SIZE: 12px;color:#646464" face=宋体 size=1>1</FONT></DIV>
</TD>
<TD>
<INPUT id="alt1" type="text" name="txt1" onfocus="textshow1('请填写1')" onblur="texthide(this)" style="display:block" maxLength=100 >
</TD>
<td><span id="p1"> <span><td>
</TR>
</table>
<SCRIPT language=javascript>
function textshow1(wordstr) {
document.getElementById('p1').innerHTML=wordstr;
}
function texthide(e){
e.style.display="none";
document.getElementById('p1').innerHTML=e.value;
}
</SCRIPT>