summaryrefslogtreecommitdiff
path: root/includes/view/AngelTypes_view.php
diff options
context:
space:
mode:
authorIgor Scheller <igor.scheller@igorshp.de>2018-11-20 16:02:03 +0100
committermsquare <msquare@notrademark.de>2018-11-21 19:24:36 +0100
commit944c29b96429ec95ac1371cb33cc43704a60c7b1 (patch)
tree7be99e68d8c15fc7e210a4b3ccc44861a8d1de64 /includes/view/AngelTypes_view.php
parentfd37c9d60ea818dc9a562fa88ff5f9a50132506f (diff)
Require POST for sending forms
* Ensure that the form is submitted with a post request * Replaced several links with forms Closes #494 (Security Vulnerability)
Diffstat (limited to 'includes/view/AngelTypes_view.php')
-rw-r--r--includes/view/AngelTypes_view.php17
1 files changed, 6 insertions, 11 deletions
diff --git a/includes/view/AngelTypes_view.php b/includes/view/AngelTypes_view.php
index 58c9567b..ab4ce517 100644
--- a/includes/view/AngelTypes_view.php
+++ b/includes/view/AngelTypes_view.php
@@ -53,17 +53,12 @@ function AngelType_delete_view($angeltype)
{
return page_with_title(sprintf(__('Delete angeltype %s'), $angeltype['name']), [
info(sprintf(__('Do you want to delete angeltype %s?'), $angeltype['name']), true),
- buttons([
- button(page_link_to('angeltypes'), glyph('remove') . __('cancel')),
- button(
- page_link_to(
- 'angeltypes',
- ['action' => 'delete', 'angeltype_id' => $angeltype['id'], 'confirmed' => 1]
- ),
- glyph('ok') . __('delete'),
- 'btn-danger'
- )
- ])
+ form([
+ buttons([
+ button(page_link_to('angeltypes'), glyph('remove') . __('cancel')),
+ form_submit('delete', glyph('ok') . __('delete'), 'btn-danger', false),
+ ])
+ ]),
]);
}