Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

how to debug javascript in IE for an asp file?

Status
Not open for further replies.

920506

Programmer
Jun 13, 2003
201
US
Hi all,
I have the following javascript in a asp file.
<script language="JavaScript">
<!--
window.onload=function() {
if (<%=inumberofQuoted %> != 0) {
//alert(parseInt(<%=inumberofQuoted %>));
<%for k=0 to inumberofQuoted -1 %>
//alert("I am here");
//alert(<%=k%>);
//alert(document.getElementById("<%=aQuoteName(k)%>Premium"));
document.getElementById("<%=aQuoteName(k)%>Premium").innerHTML='$'+parseFloat(<%=Participant(k)("Basic")%>);
//alert('<%=aQuoteName(k)&"Premium"%>');
//alert(parseFloat(<%=Participant(k)("Basic")%>));

<%Next%>
alert("<%=sSelectPlus%>");
alert(parseFloat(<%=iTotalofSelectPlus%>));
alert(parseFloat(<%=iTotalDue%>));
document.getElementById("SelectPlus").innerHTML='$'+parseFloat(<%=iTotalofSelectPlus%>);
document.getElementById("TotalPayment").innerHTML='$'+parseFloat(<%=iTotalDue%>);
}
}

//-->
</script>
In firefox, it can display innerHTML correctly without any problem. But when I tested in IE, it can display premium fine, but it cannot display "iTotalofSelectPlus" and "itotalDue". Can you help?
My testing link is
Thank you
But
 
Hi all,
I got it. It seems firefox is more torelate for the naming.
It is because I have an input type checkbox with name "SelectPlus" and also I have a div named "SelectPlus" too.
When I changed to different name for the checkbox, it ends up fine.
But still if there is a good debugger, that will be nice.
Can you give me some information for Javascript debugger?

Thank you.
Betty
 
You might find more help for javascript related issues in forum216

------------------------------------------------------------------------------------------------------------------------
"Men occasionally stumble over the truth, but most of them pick themselves up and hurry off as if nothing ever happened."
- Winston Churchill
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top