| 网站首页 | 业界新闻 | 小组 | 威客 | 人才 | 下载频道 | 博客 | 代码贴 | 在线编程 | 编程论坛
欢迎加入我们,一同切磋技术
用户名:   
 
密 码:  
共有 631 人关注过本帖
标题:请教大家一个问题?
只看楼主 加入收藏
wangwang1131
Rank: 2
等 级:论坛游民
帖 子:38
专家分:10
注 册:2006-8-5
收藏
 问题点数:0 回复次数:3 
请教大家一个问题?
我在Frontpage里测试代码。没有任何错误。可在IE浏览时提示对象不支持此属性或方法?
怎么会这样的哦?
搜索更多相关主题的帖子: 测试 
2006-09-15 07:49
live41
Rank: 10Rank: 10Rank: 10
等 级:贵宾
威 望:67
帖 子:12442
专家分:0
注 册:2004-7-22
收藏
得分:0 
代码帖出来吧,可能是拼错关键字而已
2006-09-15 12:48
wangwang1131
Rank: 2
等 级:论坛游民
帖 子:38
专家分:10
注 册:2006-8-5
收藏
得分:0 

下面的代码:
<!--#include file="Conn.ASP"-->
<!--include file="char.inc"-->
<!--#include file="chkuser.asp" -->
<%
id=request("id")
if id="" then
id=0
else
id=id
end if
%>

<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<LINK href=site.css rel=stylesheet>

<SCRIPT LANGUAGE="JavaScript" defer>
<!--
function runChgbgColor(TabID){
var obj=null;
function ChgbgColor(TabID){
var oRows=document.all(TabID).all.tags("TR");
for(var i=0;i<oRows.length;i++)
{
oRows[i].onmouseover=function(){
this.bgColor="#99CCFF";}
oRows[i].onmouseout=function(){
this.bgColor="#EAEAF4";}
oRows[i].onmousedown=function(){
this.bgColor="#EAEAF4";}
}
}
ChgbgColor(TabID);
}
//-->
</SCRIPT>
<SCRIPT language=JavaScript>
i=1;
function add(){
/*var i=2;
var row = DataTable.insertRow(i+1)
var cell = row.insertCell(0)
cell.innerHTML="jowing test"
row.style.backgroundColor="#FFFFFF"
cell = row.insertCell(1)
cell.innerHTML="<input name='Doctor' type='text' class='line_input' size='8' onmouseover='this.focus()'>"
row.style.backgroundColor="#FFFFFF"
*/
var newTR = DataTr.cloneNode(true);
newTR.id="a"+(++i)
DataTr.parentNode.insertAdjacentElement("beforeEnd",newTR);
RowReset()
}
function RowReset(){
var RowCount=MtvTab.rows.length-1
var ReName=RowCount-2
for (var i=0;i<MtvTab.rows[RowCount].cells.length;i++){

var str=MtvTab.rows[RowCount].cells[i].innerHTML
str=(str.replace(/name=[\d]*/i,"name="+ReName)).replace(/value=[\w]*/i,"value=''").replace(/(GetIncomeSum)\(\'0/i,"GetIncomeSum('"+ReName);
MtvTab.rows[RowCount].cells[i].innerHTML=str
}
}
function del(){
var c = document.getElementsByName('tt');
for(var i=0; i<c.length; i++)
if(c[i].checked)
MtvTab.deleteRow(i);
}
function ShortcutKey(){
if(window.event.keyCode==13)
add()
}
document.onkeydown=ShortcutKey;
</SCRIPT>
</head>

<body topmargin="0">

<table onMouseover="runChgbgColor('MtvTab')" id="MtvTab" style="BORDER-COLLAPSE: collapse" cellSpacing=0 cellPadding=0 width=100% bgColor=#ffffff border=1>
<tr align="center" >
<td width="5%" background="images/default_05.gif">&nbsp;ID</td>
<%
Set rs = Server.CreateObject("ADODB.Recordset")
sql ="select * From bigtype where btxh=7 and btview=1 and btid=1 order by btorder"
rs.open sql,conn,1,3
do while not rs.eof
%>
<td width="5%" background="images/default_05.gif">&nbsp;<%=rs("btsname")%></td>
<%
rs.movenext
loop
rs.close
set rs=nothing
%>
</tr>
<%

Set rs1 = Server.CreateObject("ADODB.Recordset")
sql ="select * From smalltype where kid="&id&" order by id"
rs1.open sql,Conn,1,3
%>
<form name="form1" method="post">
<%
do while not rs1.eof %>
<tr id="DataTr" bgcolor="#EAEAF4" >
<td >&nbsp; <%=rs1("id")%></td>
<td >&nbsp; <input size="8"value="<%=rs1("kid")%>"></td>
<td >&nbsp;
<input size="8"value="<%=rs1("kname")%>"></td>
<td>&nbsp;
<input size="8" value="<%=rs1("kename")%>"></td>
<td>&nbsp;
<input size="8" value="<%=rs1("kbh")%>"></td>
</tr>
<%
rs1.movenext
loop
rs1.close
set rs1=nothing
%>
</form>
</table>
</body>

</html>
在Frontpage里测试代码没有错误。在IE浏览的时候提示这行var newTR = DataTr.cloneNode(true);对象不支持此属性或方法
麻烦高手看看。这是为什么?

2006-09-17 11:44
wangwang1131
Rank: 2
等 级:论坛游民
帖 子:38
专家分:10
注 册:2006-8-5
收藏
得分:0 

没有高手帮帮我吗?

2006-09-20 07:36
快速回复:请教大家一个问题?
数据加载中...
 
   



关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 0.017716 second(s), 8 queries.
Copyright©2004-2024, BCCN.NET, All Rights Reserved