使XForms 在IE中运行

最近在 www.w3schools.com 看了一篇关于 XForms 的教程。可是在IE里实验,居然什么也显示不出来。于是在网上搜索相关的信息,最后找到了解决办法,写到这里与大家分享。
1、下载并安装 IBM XML Forms Package,关于这个包的具体信息可以浏览后面的网址。( http://alphaworks.ibm.com/tech/xmlforms )
2、下载并安装最近的XML Parser。( http://www.microsoft.com/downloads/details.aspx?displaylang=zh-cn&FamilyID=c0f86022-2d4c-4162-8fb8-66bfc12f32b0 ).

以下是xforms的例子,摘自 w3schools。存为 helloworld.xforms 即可。在完成以上两步后就可以在IE中打开这个文件测试了。

 1<html xmlns:xforms="  http://www.w3.org/2002/xforms/cr  ">
 2<head>
 3<xforms:model>
 4<xforms:instance>
 5<person>
 6<fname></fname>
 7<lname></lname>
 8</person>
 9</xforms:instance>
10<xforms:submission action="submit.jsp" id="form1" method="get"></xforms:submission>
11</xforms:model>
12</head>
13<body>
14<xforms:input ref="fname">
15<xforms:label>First Name</xforms:label>
16</xforms:input>
17<br/>
18<xforms:input ref="lname">
19<xforms:label>Last Name</xforms:label>
20</xforms:input>
21<br/>
22<br/>
23<xforms:submit submission="form1">
24<xforms:label>Submit</xforms:label>
25</xforms:submit>
26</body>
27</html>
Published At
Categories with Web编程
Tagged with
comments powered by Disqus