XML 验证:解析属性名称时出错
我遇到了 XML 验证问题。这一点:
<script type="text/javascript">
oxm_ad = {"website":"cca9e4b4-7ed2-848z-ffea-067efabc891a",
"size":"468x60",
"floor":"0.01",
"beacon":"<div id='beacon_017a6c9ega' style='position: absolute; left: 0px; top: 0px; visibility: hidden;'><img src='http://www.website.com/openx/www/delivery/lg.php?bannerid=1&campaignid=1&zoneid=4&loc=http%3a%2f%2flocalhost%2fproject-debug%2fproject.html&cb=014a7c8eda&bannerid=-1' width='0' height='0' alt='' style='width: 0px; height: 0px;' </img></div>",
"fallback":"<a href='http://www.website.com/openx/www/delivery/ck.php?oaparams=2__bannerid=1__zoneid=4__cb=014a7c8eda__oadest=http%3a%2f%2fwww.website.com' target='_blank'><img src='http://www.website.com/openx/www/delivery/ai.php?filename=mybanner.png&contenttype=png' width='468' height='60' alt='' title='' border='0' /></a><div id='beacon_014a7c8eda' style='position: absolute; left: 0px; top: 0px; visibility: hidden;'><img src='http://www.website.com/openx/www/delivery/lg.php?bannerid=1&campaignid=1&zoneid=4&loc=http%3a%2f%2flocalhost%2fproject-debug%2fproject.html&cb=014a7c8eda' width='0' height='0' alt='' style='width: 0px; height: 0px;' </img></div>"};
</script>
结果是:
该页面包含以下内容 错误:第 5 行第 246 列错误: 解析属性名称时出错
我不确定我的错误是什么。关于如何纠正这个问题有什么建议吗?
谢谢你!
-拉克斯米迪
I've got an XML validation problem. This bit:
<script type="text/javascript">
oxm_ad = {"website":"cca9e4b4-7ed2-848z-ffea-067efabc891a",
"size":"468x60",
"floor":"0.01",
"beacon":"<div id='beacon_017a6c9ega' style='position: absolute; left: 0px; top: 0px; visibility: hidden;'><img src='http://www.website.com/openx/www/delivery/lg.php?bannerid=1&campaignid=1&zoneid=4&loc=http%3a%2f%2flocalhost%2fproject-debug%2fproject.html&cb=014a7c8eda&bannerid=-1' width='0' height='0' alt='' style='width: 0px; height: 0px;' </img></div>",
"fallback":"<a href='http://www.website.com/openx/www/delivery/ck.php?oaparams=2__bannerid=1__zoneid=4__cb=014a7c8eda__oadest=http%3a%2f%2fwww.website.com' target='_blank'><img src='http://www.website.com/openx/www/delivery/ai.php?filename=mybanner.png&contenttype=png' width='468' height='60' alt='' title='' border='0' /></a><div id='beacon_014a7c8eda' style='position: absolute; left: 0px; top: 0px; visibility: hidden;'><img src='http://www.website.com/openx/www/delivery/lg.php?bannerid=1&campaignid=1&zoneid=4&loc=http%3a%2f%2flocalhost%2fproject-debug%2fproject.html&cb=014a7c8eda' width='0' height='0' alt='' style='width: 0px; height: 0px;' </img></div>"};
</script>
results in:
This page contains the following
errors: error on line 5 at column 246:
error parsing attribute name
I'm not sure what my error is. Any suggestions on how to correct this problem?
Thank you!
-Laxmidi
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
您似乎缺少两个
标记上的结尾
>
。即它应该是:而不是您当前所拥有的:
下一行有相同的错误。看看是否可以解决问题?
It looks like you're missing the end
>
on both of your<img>
tags. I.e. it should be:Instead of what you currently have:
The next line has the same error. See if that fixes the problem?
标签现在没有配对
结束标签,而是使用
< /代码>
<img>
tag now has no paired</img>
end tag instead use<img src="...." />