initial import
[roojs1] / examples / form / xml-form.html
1 <html>
2 <head>
3 <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
4 <title>XML Form</title>
5   <link rel="stylesheet" type="text/css" href="../../cssX/roojs-all.css"/>
6     <link rel="stylesheet" type="text/css" href="../../cssX/xtheme-slate.css"/>
7
8     <script type="text/javascript" src="../../roojs-debug.js"></script>   
9    
10         
11     <script type="text/javascript" src="states.js"></script>
12     <script type="text/javascript" src="xml-form.js"></script>
13     <link rel="stylesheet" type="text/css" href="forms.css" />
14
15 <!-- Common Styles for the examples -->
16     <link rel="stylesheet" type="text/css" href="../examples.css" />
17 </head>
18 <body>
19     <script type="text/javascript" src="../examples.js"></script><!-- EXAMPLES -->
20 <h1>Loading/Saving a Dynamic Form using XML</h1>
21 <p>
22     This is a very simple example of using XML for load and submit of data with an Ext dynamic form. (It's probably better to use the JSON tools)
23 </p>
24 <p>
25     Click "Load" to load the <button type="button" onclick="RooDocs.viewSource.show('/xml-form.xml')">xml-form.xml</button> 
26     om the server using an XmlReader.
27 </p>
28 <p>
29     After loading the form, you will be able to hit submit. The submit action will make a post to the server,
30     
31     
32     and the<button type="button" onclick="RooDocs.viewSource.show('/xml-errors.xml')">dummy XML file</button> 
33     on the server with test server-side validation failure messages will be sent back.
34     Those messages will be applied to the appropriate fields in the form.
35 </p>
36 <p>
37     Note: The built-in JSON support does not require any special readers for mapping. However, If you don't like the Form's built-in JSON format, you could also use a JsonReader for reading data into a form.
38 </p>
39 <p>The js is not minified so it is readable. See
40 <button type="button" onclick="RooDocs.viewSource.show('/xml-form.js')">xml-form.js</button> .</p>
41
42 <div style="width:340px;">
43     <div class="x-box-tl"><div class="x-box-tr"><div class="x-box-tc"></div></div></div>
44     <div class="x-box-ml"><div class="x-box-mr"><div class="x-box-mc" id="box-bd">
45         <h3>XML Form</h3>
46         <div id="form-ct">
47
48         </div>
49     </div></div></div>
50     <div class="x-box-bl"><div class="x-box-br"><div class="x-box-bc"></div></div></div>
51 </div>
52 <div class="x-form-clear"></div>
53 </body>
54 </html>