Photos
Blog
Projects
vanrenterghem.biz
projects
/
git.ikiwiki.info.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge remote branch 'smcv/trivia'
[git.ikiwiki.info.git]
/
IkiWiki
/
Plugin
/
remove.pm
diff --git
a/IkiWiki/Plugin/remove.pm
b/IkiWiki/Plugin/remove.pm
index cbc8a0f2ce70719e770fc64853feaaa37252f23b..f59d0269e4cc747da68db81b56afd82cdc304cee 100644
(file)
--- a/
IkiWiki/Plugin/remove.pm
+++ b/
IkiWiki/Plugin/remove.pm
@@
-18,6
+18,7
@@
sub getsetup () {
plugin => {
safe => 1,
rebuild => 0,
plugin => {
safe => 1,
rebuild => 0,
+ section => "web",
},
}
},
}
@@
-51,7
+52,7
@@
sub check_canremove ($$$) {
IkiWiki::Plugin::attachment::check_canattach($session, $page, $file);
}
else {
IkiWiki::Plugin::attachment::check_canattach($session, $page, $file);
}
else {
- error("re
naming
of attachments is not allowed");
+ error("re
moval
of attachments is not allowed");
}
}
}
}
@@
-166,7
+167,7
@@
sub formbuilder (@) {
removal_confirm($q, $session, 0, $form->field("page"));
}
elsif ($form->submitted eq "Remove Attachments") {
removal_confirm($q, $session, 0, $form->field("page"));
}
elsif ($form->submitted eq "Remove Attachments") {
- my @selected=$q->param("attachment_select");
+ my @selected=
map { Encode::decode_utf8($_) }
$q->param("attachment_select");
if (! @selected) {
error(gettext("Please select the attachments to remove."));
}
if (! @selected) {
error(gettext("Please select the attachments to remove."));
}
@@
-187,7
+188,7
@@
sub sessioncgi ($$) {
postremove($session);
}
elsif ($form->submitted eq 'Remove' && $form->validate) {
postremove($session);
}
elsif ($form->submitted eq 'Remove' && $form->validate) {
- my @pages=$
q->param
("page");
+ my @pages=$
form->field
("page");
# Validate removal by checking that the page exists,
# and that the user is allowed to edit(/remove) it.
# Validate removal by checking that the page exists,
# and that the user is allowed to edit(/remove) it.
@@
-237,7
+238,7
@@
sub sessioncgi ($$) {
}
}
else {
}
}
else {
- removal_confirm($q, $session, 0, $
q->param
("page"));
+ removal_confirm($q, $session, 0, $
form->field
("page"));
}
exit 0;
}
exit 0;