日期:2014-05-19  浏览次数:20419 次

这个asp.net网页为什么老是提示脚本错误
<%@   Page   Language= "C# "   AutoEventWireup= "true "     CodeFile= "Default.aspx.cs "   Inherits= "_Default "   %>

<!DOCTYPE   html   PUBLIC   "-//W3C//DTD   XHTML   1.0   Transitional//EN "   "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd ">

<html   xmlns= "http://www.w3.org/1999/xhtml "   >
<head   runat= "server ">
        <title> Untitled   Page </title>
       
<object   id= "informationCards "   name= "informationCards "  
    type= "application/x-informationCard "   >
    <param   name= "issuer "  
value= "http://schemas.xmlsoap.org/ws/2005/05/identity/issuer/self "/>
    <param   name= "tokenType "   value= "urn:oasis:names:tc:SAML:1.0:assertion "/>
    <param   name= "requiredClaims "   value= "http://schemas.xmlsoap.org/ws/
2005/05/identity/claims/privatepersonalidentifier  
http://schemas.xmlsoap.org/ws/2005/05/identity/claims/emailaddress "/>
    <param   name= "optionalClaims "   value= "http://schemas.xmlsoap.org/ws/
2005/05/identity/claims/dateofbirth "/>
</object>

</head>

        <script   type= "text/javascript "   language= "javascript ">
function   SelectInformationCard()
{
var   infoCardObject   =document.getElementById( "informationCards ");
var   hiddenToken.value   =   "empty ";
hiddenToken.value   =   infoCardObject.value;
alert(hiddenToken.value);
}
</script>

<body>
        <form   id= "form1 "   runat= "server "     method= "post ">
          <asp:Button   ID= "cardSpaceSubmit "   runat= "server "   OnClientClick= "SelectInformationCard() "   />      
          <input   id= "hiddenXmlToken "   type= "hidden "     name= "hiddenXmlToken "   value= "empty "   />  
 
          </form>
</body>
</html>


------解决方案--------------------
hiddenToken没有定义吧
------解决方案--------------------
var hiddenToken.value = "empty ";
hiddenToken.value = infoCardObject.value;


hiddenToken???from where ?
------解决方案--------------------
还有一个informationCards从那里来的?