]> CyberLeo.Net >> Repos - SourceForge/phpwiki.git/blob - themes/Crao/templates/editpage.tmpl
new Crao theme by Arnaud Fontaine and Laurent Lunati
[SourceForge/phpwiki.git] / themes / Crao / templates / editpage.tmpl
1 <!-- -*-html-*- -->
2 <!-- $Id: editpage.tmpl,v 1.1 2004-05-12 19:42:16 rurban Exp $ -->
3 <?php
4 $WidthI = HTML::input(array('type' => 'text',
5                             'size' => 3,
6                             'maxlength' => 4,
7                             'class' => "numeric",
8                             'name' => 'pref[editWidth]',
9                             'value' => $request->getPref('editWidth'),
10                             'onchange' => 'this.form.submit();'));
11
12 $HeightI = HTML::input(array('type' => 'text',
13                              'size' => 3,
14                              'maxlength' => 4,
15                              'class' => "numeric",
16                              'name' => 'pref[editHeight]',
17                              'value' => $request->getPref('editHeight'),
18                              'onchange' => 'this.form.submit();'));
19
20
21 $s = $Theme->getButtonSeparator();
22 ?>
23 <?php if (isset($PREVIEW_CONTENT)) { ?>
24   <p><strong><?=_("Preview only!  Changes not saved.")?></strong>
25 <!-- FIXME: it would be nice to put a link to the #editarea anchor below,
26      but it does not work currently with the <base> declared in top.tmpl.
27      I think we need to do away with using <base> altogether... -->
28      <?= fmt("Please continue editing.  (You'll find your %s at the bottom of the page.)",
29           /* HTML::a(array("href" => "#editarea"), */ _("edit area") /*)  */) ?>
30   </p>
31   <hr class="printer" noshade="noshade" />
32   <?= $PREVIEW_CONTENT ?>
33   <hr class="printer" noshade="noshade" />
34 <?php } ?>
35 <?= $PAGE_LOCKED_MESSAGE ?>
36 <?= $CONCURRENT_UPDATE_MESSAGE ?>
37 <?php if (! $IS_CURRENT) { ?>
38   <p><strong><?=_("Warning: You are editing an old revision.")?>
39         <?=_("Saving this page will overwrite the current version.")?></strong></p>
40 <?php } ?>
41 <?php /*
42  * FIXME: Hack! 
43  * The funky URL used for the form action parameter is bogus.
44  * This is needed, otherwise the redirect to the real browser
45  * page won't work with some browsers. (NS4 and Mozilla 0.97 won't accept
46  * a redirect from a page to itself.)
47  *
48  * <textarea wrap="virtual"> is not valid xhtml but Netscape 4 requires it
49  * to wrap long lines.
50  *
51  */ ?>
52 <form method="post" name="editpage"
53       action="<?= $request->getPostURL() ?>"
54       accept-charset="<?=CHARSET?>">
55   <?php /* To clear beyond a larger logo, such as in the Hawaiian theme */ ?>
56   <br />
57   <fieldset id="editarea-size">
58     <label><?=_("Edit Area Size:")?>
59     <label><b><?=_("H")?></b> <?=$HeightI?></label>
60     <label><b><?=_("W")?></b> <?=$WidthI?></label></label>
61     <noscript><?=Button("submit:", _("Adjust"), 'wikiaction')?></noscript>
62   </fieldset>
63   <fieldset class="editarea">
64   <legend><?=_("Page Content: ")?></legend>
65   <?=$EDIT_TEXTAREA?>
66 </fieldset>
67 <!-- FIXME: fix layout, move CSS to CSS -->
68  <fieldset class="editarea">
69 <legend><?=_("Summary:")?></legend>
70 <br /> <?=$SUMMARY_INPUT?>
71 </fieldset>
72   <fieldset class="toolbar"> 
73     <?=$MINOR_EDIT_CB ?> <?=_("This is a minor change.")?>&nbsp;&nbsp;
74     <?=$OLD_MARKUP_CB?>  <?=_("Use old markup")?>
75   </fieldset>
76   <fieldset class="toolbar">
77     <?= $PREVIEW_B ?>
78     <?php if ($SAVE_B)  { ?> 
79       <?=$s?><?= $SAVE_B ?>
80     <?php } ?>
81   </fieldset>
82   <fieldset class="toolbar">
83     <?= $user->isSignedIn()
84         ? ''
85         : fmt("Author will be logged as %s.", HTML::em($user->getId())) ?>
86     <label><?= Template('signin', array('FORMNAME' => 'editpage')) ?></label>
87   </fieldset>
88 <?php if ($user->isadmin()) { ?>
89   <fieldset class="toolbar">
90     <label><?= $LOCKED_CB ?> <?=_("Locked")?></label>
91   </fieldset>
92 <?php } ?>
93 <hr noshade="noshade" />
94 <script language="JavaScript1.3" type="text/javascript">
95 <!--
96 function showOldMarkupRules(show) {
97   if (document.getElementById) {
98     if (!show) {
99       document.getElementById('newMarkup').style.display="block";
100       document.getElementById('oldMarkup').style.display="none";
101     } else {
102       document.getElementById('newMarkup').style.display="none";
103       document.getElementById('oldMarkup').style.display="block";
104     }
105   }
106 }
107 // -->
108 </script>
109 <div id="oldMarkup" class="wiki-edithelp">
110 <!-- FIXME: do we need this at all?  If so, it could probably be moved to TextFormattingRules -->
111 <p><?= fmt("See %s tips for editing.", WikiLink(_("GoodStyle"))) ?></p>
112 <?plugin IncludePage page=_("OldTextFormattingRules") section=_("Synopsis") quiet=1?>
113 </div>
114 <div id="newMarkup" class="wiki-edithelp">
115 <!-- FIXME: do we need this at all?  If so, it could probably be moved to TextFormattingRules -->
116 <p><?= fmt("See %s tips for editing.", WikiLink(_("GoodStyle"))) ?></p>
117 <?plugin IncludePage page=_("TextFormattingRules") section=_("Synopsis") quiet=1?>
118 </div>
119 <?=$HIDDEN_INPUTS?>
120 </form>
121 <script language="JavaScript1.3" type="text/javascript">
122 <!--
123 if (document.getElementById) {
124   showOldMarkupRules(document.getElementById('useOldMarkup').checked);
125 }
126 // -->
127 </script>