[Pmwiki-users] confirm dialoge for the Reset button! => define CANCEL-button
Knut Alboldt
mailing
Mon Aug 30 05:58:08 CDT 2004
At 09:49 30.08.2004, you wrote:
>Hi,
>
>I've run into this myself. How about just removing the "Reset" button
>altogether? I've used MediaWiki quite a bit and find the "Cancel" button
>useful, so that might be a useful replacement.
It's easy to implement:
in config.php change the variable $PageEditFmt (copied from pmwiki.php).
Add a line
<input class='formbutton' type='submit' name='cancel' value=' $[Cancel] ' />
(or replace the reset-definition)
then further on in config.php add the following code:
# editpage was left with cancel button: display unchanged page
if (@$_POST['cancel'])
{
# TODO: go back to referer
Redirect($pagename);
}
It only doesn't work with canceling new pages cause then this new not
created page should be displaed which results in a 404. So it would be
better to go to the groups homepage instead or to the calling page
(whereever you can get this info)
Knut
More information about the pmwiki-users
mailing list