2 <!-- $Id: editpage.tmpl,v 1.10 2002-01-28 01:01:27 dairiki Exp $ -->
4 $SummaryInput = HTML::input(array('type' => 'text',
8 'value' => $FORMVARS['summary']));
10 $MinorEditCb = HTML::input(array('type' => 'checkbox',
11 'name' => 'minor_edit',
12 'checked' => (bool) $FORMVARS['minor_edit']));
14 $PreviewB = HTML::input(array('type' => 'submit',
17 'value' => _("Preview")));
18 $SaveB = HTML::input(array('type' => 'submit',
21 'value' => _("Save")));
23 $WidthI = HTML::input(array('type' => 'text',
25 'name' => 'pref[editWidth]',
26 'value' => $request->getPref('editWidth'),
27 'onchange' => 'this.form.submit();'));
29 $HeightI = HTML::input(array('type' => 'text',
31 'name' => 'pref[editHeight]',
32 'value' => $request->getPref('editHeight'),
33 'onchange' => 'this.form.submit();'));
35 $AdjustB = $Theme->makeButton(_("Adjust"), "submit:");
38 $GoodStyleB = $Theme->makeLinkButton(_("GoodStyle"));
41 $Markup['old'] = new HtmlElement('option', array('value' => 'old'),
43 $Markup['new'] = new HtmlElement('option', array('value' => 'new'),
45 $selected = $FORMVARS['markup'] == 'new' ? 'new' : 'old';
46 $Markup[$selected]->setAttr('selected', true);
47 $MarkupSelect = new HtmlElement('select', array('name' => 'markup'),
50 $s = $Theme->getButtonSeparator();
55 * The funky URL used for the form action parameter is bogus.
56 * This is needed, otherwise the redirect to the real browser
57 * page won't work with some browsers. (NS4 and Mozilla 0.97 won't accept
58 * a redirect from a page to itself.)
60 * <textarea wrap="virtual"> is not valid xhtml but Netscape 4 requires it
65 <form method="post" name="editpage"
66 action="<?=WikiURL($page,array('action'=>'edit'))?>"
67 accept-charset="<?=CHARSET?>">
68 <table summary="Toolbar: Save, Preview, and edit warnings." class="toolbar" width="100%"
69 cellpadding="0" cellspacing="0" border="0"><tr align="baseline">
71 <?php if (!$revision->isCurrent()) { ?>
72 <p><strong><?=_("Warning: You are editing an old revision.")?>
73 <?=_("Saving this page will overwrite the current version.")?></strong></p>
75 <?php if (isset($PREVIEW_CONTENT)) { ?>
76 <p><strong><?=_("Preview only! Changes not saved.")?></strong></p>
79 <td align="right"><?= $PreviewB ?><?=$s?><?= $SaveB ?></td></tr>
80 <?php if (isset($PREVIEW_CONTENT)) { ?>
83 <div class="wikitext"><?= $PREVIEW_CONTENT ?></div>
87 <textarea class="wikiedit"
89 rows="<?=$request->getPref('editHeight')?>"
90 cols="<?=$request->getPref('editWidth')?>"
91 wrap="virtual"><?=$FORMVARS['content']?></textarea>
93 <?=_("Summary:")?> <?= $SummaryInput ?>
95 <?= fmt("Author will be logged as %s.", HTML::em($user->getId())) ?>
98 <?= fmt("I'm just doing minor edits. Please divert the usual logging to %s instead.",
99 $Theme->linkExistingWikiWord(_("RecentEdits"))) ?>
102 <?=_("Edit Area Size:")?> <b><?=_("H")?></b>
108 Markup Style: <?=$MarkupSelect?>
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.", $GoodStyleB) ?></p>
112 <div class="wiki-edithelp">
113 <?plugin IncludePage page=_("TextFormattingRules") section=_("Synopsis") quiet=1?>
115 <input type="hidden" name="action" value="save" />
116 <input type="hidden" name="pagename" value="<?=$FORMVARS['pagename']?>" />
117 <input type="hidden" name="editversion" value="<?=$FORMVARS['editversion']?>" />
118 <input type="hidden" name="version" value="<?=$FORMVARS['version']?>" />