首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 网站开发 > XML SOAP >

在IE中怎么验证xml文档

2012-02-22 
在IE中如何验证xml文档我的xml文档如下:?xmlversion 1.0 encoding ISO-8859-1 ?personsxmlns h

在IE中如何验证xml文档
我的xml文档如下:
<?xml   version= "1.0 "   encoding= "ISO-8859-1 "?>
<persons   xmlns= "http://my-company.com/namespace "   xmlns:xsi= "http://www.w3.org/2001/XMLSchema-instance "  
xsi:schemaLocation= "http://my-company.com/namespace   family.xsd ">
<child_name> Cecilie </child_name>  
<full_name> Hege   Refsnes </full_name>  
</persons>  
我的xsd文件如下:
<?xml   version= "1.0 "   encoding= "ISO-8859-1 "?>  
<xs:schema   xmlns= "http://my-company.com/namespace "   xmlns:xs= "http://www.w3.org/2001/XMLSchema "   targetNamespace= "http://my-company.com/namespace "   elementFormDefault= "qualified "
>
<xs:element   name= "persons ">  
<xs:complexType>  
<xs:sequence>  
<xs:element   name= "full_name "   type= "xs:string "/>  
<xs:element   name= "child_name "   type= "xs:string "   minOccurs= "1 "   maxOccurs= "5 "/>  
</xs:sequence>  
</xs:complexType>  
</xs:element>  
</xs:schema>  

在xmlspy中报异常元素 'child_name '在元素 'persons '中,期望full_name.
但在IE中确什么错都不报,如何让IE也报错呢

[解决办法]
目前IE不带有效验证的功能.

热点排行