[英]Issue with dojo dijit.form.ValidationTextBox
以下XHTML代码无效:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<link rel="stylesheet" type="text/css" href="/dojotoolkit/dijit/themes/tundra/tundra.css" />
<link rel="stylesheet" type="text/css" href="/dojotoolkit/dojo/resources/dojo.css" />
<script type="text/javascript" src="/dojotoolkit/dojo/dojo.js" djConfig="parseOnLoad: true" />
<script type="text/javascript">
dojo.require("dijit.form.ValidationTextBox");
dojo.require("dojo.parser");
</script>
</head>
<body class="nihilo">
<input type="text" dojoType="dijit.form.ValidationTextBox" size="30" />
</body>
</html>
在Firebug中,我收到以下错误消息:
[例外...“组件返回失败代码:0x80004003(NS_ERROR_INVALID_POINTER)[nsIDOMNSHTMLElement.innerHTML]”nsresult:“0x80004003(NS_ERROR_INVALID_POINTER)”location:“JS frame :: http:// localhost:21000 / dojotoolkit / dojo / dojo。 js :: anonymous :: line 319“data:no] http:// localhost:21000 / dojotoolkit / dojo / dojo.js第319行
知道什么是错的吗?
问题接缝是文件的结尾......
两个接缝之间的偏差是apache响应头中的Content-Type。
您导入dojo.js的位置:
<script type="text/javascript" src="/dojotoolkit/dojo/dojo.js" djConfig="parseOnLoad: true"/>
它应该是:
<script type="text/javascript" src="/dojotoolkit/dojo/dojo.js" djConfig="parseOnLoad:true"></script>
与道场玩得开心,它可以做一些很酷的东西。
Brian Gianforcaro
在dojo trac页面上有一些类似的票:
http://trac.dojotoolkit.org/search?q=xhtml+ns_error&noquickjump=1&ticket=on
可能你遇到了一个错误,你需要填写一张新票。
那么,dojo.js在319行做什么?
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.