efe077f84ad07dfc3eee8403333a7137e57de1db
[ikiwiki.git] / templates / editpage.tmpl
1 <TMPL_VAR JAVASCRIPT>
2 <TMPL_VAR MESSAGE>
3 <br />
4 <TMPL_VAR FORM-START>
5 <TMPL_VAR FIELD-DO>
6 <TMPL_VAR FIELD-SID>
7 <TMPL_VAR FIELD-FROM>
8 <TMPL_VAR FIELD-RCSINFO>
9 <TMPL_VAR FIELD-NEWFILE>
10 <TMPL_IF NAME="PAGE_SELECT">
11 <label for="page" class="inline">Page location:</label><TMPL_VAR FIELD-PAGE>
12 <label for="type" class="inline">Page type:</label><TMPL_VAR FIELD-TYPE>
13 <TMPL_ELSE>
14 <TMPL_VAR FIELD-PAGE>
15 <TMPL_VAR FIELD-TYPE>
16 </TMPL_IF>
17 <div class="editcontentdiv">
18 <TMPL_VAR FIELD-EDITCONTENT><br />
19 </div>
20 <TMPL_IF NAME="CAN_COMMIT">
21 <label for="editmessage" class="block">Optional comment about this change:</label>
22 <TMPL_VAR FIELD-EDITMESSAGE><br />
23 </TMPL_IF>
24 <TMPL_VAR FORM-SUBMIT>
25 <TMPL_VAR HELPONFORMATTINGLINK>
26 <TMPL_IF NAME="FIELD-ATTACHMENT">
27 <a class="toggle" href="#attachments">Attachments</a>
28 <div class="<TMPL_VAR ATTACHMENTS-CLASS>" id="attachments">
29 <div id="fileupload"> 
30 <script>
31 $(function () { $('#fileupload').fileupload(); }); // initialize upload widget
32 </script>
33 <script id="template-upload" type="text/x-jquery-tmpl"> 
34     <tr class="template-upload{{if error}} ui-state-error{{/if}}">
35         <td><input type="checkbox" name="attachment_select" value="${name}" />${name}</td>
36         {{if error}}
37         <td class="error" colspan="2">failed!</td>
38         {{else}}
39         <td class="progress" colspan="2"><div></div></td>
40         <td class="start"><button>Start</button></td>
41         {{/if}}
42         <td class="cancel"><button>Cancel</button></td>
43     </tr>
44 </script> 
45 <script id="template-download" type="text/x-jquery-tmpl"> 
46     <tr class="template-download{{if error}} ui-state-error{{/if}}">
47         <td><input type="checkbox" name="attachment_select" value="${name}" />${name}</td>
48         <td>${humansize}</td>
49         {{if error}}
50         <td class="error" colspan="2">failed!</td>
51         {{else}}
52         <td>${stored_msg}</td>
53         {{/if}}
54     </tr>
55 </script> 
56 <div class="fileupload-content">
57 <table class="files">
58 <TMPL_LOOP NAME="ATTACHMENT_LIST">
59 <tr><td><input type="checkbox" name="attachment_select" value="<TMPL_VAR NAME ESCAPE="HTML">" /><TMPL_VAR LINK></td><td><TMPL_VAR SIZE></td><td><TMPL_VAR MTIME></td></tr>
60 </TMPL_LOOP>
61 </table>
62 </div>
63 <TMPL_VAR FIELD-ATTACHMENT>
64 <noscript><TMPL_VAR FIELD-UPLOAD></noscript>
65 <TMPL_IF NAME="ATTACHMENT_LIST">
66 <TMPL_VAR FIELD-LINK><TMPL_VAR FIELD-RENAME><TMPL_VAR FIELD-REMOVE>
67 </TMPL_IF>
68 </div> 
69 </div>
70 </TMPL_IF>
71 <TMPL_VAR FORM-END>
72 <TMPL_VAR WMD_PREVIEW>
73 <TMPL_IF NAME="PAGE_PREVIEW">
74 <hr />
75 <div class="header">
76 <span>Page preview:</span>
77 </div>
78 <div id="preview">
79 <TMPL_VAR PAGE_PREVIEW>
80 </div>
81 </TMPL_IF>
82 <TMPL_IF NAME="PAGE_DIFF">
83 <hr />
84 <div class="header">
85 <span>Diff:</span>
86 </div>
87 <div id="diff">
88 <TMPL_VAR PAGE_DIFF>
89 </div>
90 </TMPL_IF>