]> CyberLeo.Net >> Repos - SourceForge/phpwiki.git/blob - themes/default/templates/editpage.tmpl
Use CSS
[SourceForge/phpwiki.git] / themes / default / templates / editpage.tmpl
1 <?php if (isset($PREVIEW_CONTENT)) { ?>
2   <p><strong><?php echo _("Preview only!  Changes not saved.")?></strong>
3 <!-- FIXME: it would be nice to put a link to the #editarea anchor below,
4      but it does not work currently with the <base> declared in top.tmpl.
5      I think we need to do away with using <base> altogether... -->
6      <?php echo fmt("Please continue editing.  (You'll find your %s at the bottom of the page.)",
7           /* HTML::a(array("href" => "#editarea"), */ _("edit area") /*)  */) ?>
8   </p>
9   <hr class="printer" />
10   <?php echo $PREVIEW_CONTENT ?>
11   <hr class="printer" />
12 <?php } ?>
13
14 <?php echo $PAGE_LOCKED_MESSAGE ?>
15 <?php echo $CONCURRENT_UPDATE_MESSAGE ?>
16
17 <?php if (! $IS_CURRENT) { ?>
18   <p class="warning_msg"><strong><?php echo _("Warning: You are editing an old revision.")?>
19         <?php echo _("Saving this page will overwrite the current version.")?></strong></p>
20 <?php } ?>
21 <?php /*
22  * FIXME: Hack! 
23  * The funky URL used for the form action parameter is bogus.
24  * This is needed, otherwise the redirect to the real browser
25  * page won't work with some browsers. (NS4 and Mozilla 0.97 won't accept
26  * a redirect from a page to itself.)
27  */ ?>
28 <form method="post" id="editpage" name="editpage"
29       action="<?php echo $request->getPostURL() ?>"
30       accept-charset="UTF-8">
31   <?php if (!empty($_GET['start_debug'])) echo '<input type="hidden" name="start_debug" value="1" >'; ?>
32   <?php /* To clear beyond a larger logo, such as in the Hawaiian theme */ ?>
33   <br class="clear-floats" />
34   <table class="fullwidth">
35     <tr><td><?php echo $EDIT_TOOLBAR ?></td>
36         <td class="align-right"><div id="editarea-size">
37     <?php echo _("Size").':'?>
38     <label for="pref-editHeight"><b><?php echo _("H")?></b></label> <?php echo $HEIGHT_PREF?> 
39     <label for="pref-editWidth"><b><?php echo _("W")?></b></label> <?php echo $WIDTH_PREF?>
40     <noscript><?php echo Button("submit:", _("Adjust"), 'wikiaction')?></noscript>
41   </div></td></tr></table>
42 <?php if (!empty($WYSIWYG_B)) { ?>
43   <br /><div class="hint"><strong>Warning:</strong> Switching to the Wysiwyg editor will not keep your changes.</div>
44 <?php } ?>
45   <a id="editarea"></a><?php echo $EDIT_TEXTAREA?>
46 <!-- FIXME: fix layout, move CSS to CSS -->
47 <div class="toolbar" style="text-align: center;">
48   <label for="edit-summary"><?php echo _("Summary").':'?></label> <?php echo $SUMMARY_INPUT?>
49 </div>
50 <?php if (ENABLE_CAPTCHA) { ?>
51 <div class="toolbar" style="text-align: center;">
52   <?php echo $CAPTCHA_IMAGE ?><br/>
53   <?php echo $CAPTCHA_LABEL ?><?php echo $CAPTCHA_INPUT ?>
54 </div> 
55 <?php } ?>
56 <table class="toolbar fullwidth">
57 <tr class="middle">
58   <td> 
59     <?php echo $MINOR_EDIT_CB ?> <label for="edit-minor_edit"><?php echo _("This is a minor change.")?></label><br />
60     <?php echo $OLD_MARKUP_CB ?> <label for="useOldMarkup"><?php echo _("Use old markup")?></label> <?php echo $OLD_MARKUP_CONVERT?>
61   </td>
62   <td class="align-center">
63     <?php if (!empty($WYSIWYG_B)){ ?>
64     <?php echo $WYSIWYG_B?><?php echo $SEP?>
65     <?php } ?>
66     <?php echo $PREVIEW_B ?>
67     <?php if ($SAVE_B)  { ?> 
68       <?php echo $SEP?><?php echo $SAVE_B ?>
69     <?php } ?>
70     <?php echo $SEP?><?php echo $CHANGES_B ?>
71   </td>
72   <td>&nbsp; <?php echo $AUTHOR_MESSAGE?></td>
73 </tr>
74 <tr>
75   <td>
76     <?php if ($user->isAdmin()) { ?> 
77     <?php echo $LOCKED_CB ?> <label for="edit-locked" title="<?php echo _("Make the page read-only?")?>"><?php echo _("Locked")?></label>
78     <?php if (ENABLE_PAGE_PUBLIC) { ?>
79     &nbsp;&nbsp;<?php echo $PUBLIC_CB ?> <label for="edit-public" title="<?php echo _("Export to a separate public area?")?>"><?php echo _("Public")?></label>
80     <?php }} ?>
81   </td>
82   <td colspan="2" class="align-right">
83     <?php if (!$user->isAuthenticated()) { ?>
84     <?php echo Template('signin', array('FORMNAME' => 'editpage')) ?>
85     <?php } ?>
86   </td>
87 </tr>
88 </table>
89 <?php echo $HIDDEN_INPUTS?>
90 </form>
91 <div style="width:100%;text-align:center;"><?php /*plugin UpLoad autolink=0 mode=edit size=30 */?></div>
92
93 <hr />
94
95 <script type="text/javascript">
96 <!--
97 function showOldMarkupRules(show) {
98   if (document.getElementById) {
99     if (!show) {
100       document.getElementById('newMarkup').style.display="block";
101       document.getElementById('oldMarkup').style.display="none";
102     } else {
103       document.getElementById('newMarkup').style.display="none";
104       document.getElementById('oldMarkup').style.display="block";
105     }
106   }
107 }
108 // -->
109 </script>
110
111 <div id="oldMarkup" class="wiki-edithelp">
112 <!-- FIXME: do we need this at all?  If so, it could probably be moved to TextFormattingRules -->
113 <p><?php echo fmt("See %s tips for editing.", WikiLink(_("Help")."/"._("GoodStyle"))) ?></p>
114 <?plugin IncludePage page=_("Help")."/"._("OldTextFormattingRules") section=_("Synopsis") quiet=1?>
115 </div>
116 <div id="newMarkup" class="wiki-edithelp">
117 <!-- FIXME: do we need this at all?  If so, it could probably be moved to TextFormattingRules -->
118 <p><?php echo fmt("See %s tips for editing.", WikiLink(_("Help")."/"._("GoodStyle"))) ?></p>
119 <?plugin IncludePage page=_("Help")."/"._("TextFormattingRules") section=_("Synopsis") quiet=1?>
120 </div>
121
122 <script type="text/javascript">
123 <!--
124 if (document.getElementById) {
125   showOldMarkupRules(document.getElementById('useOldMarkup').checked);
126 }
127 // -->
128 </script>