From 813f42b7159ae5eff2edcafedaf963c96a1f7e7c Mon Sep 17 00:00:00 2001 From: Carlos Proensa Date: Sun, 27 Sep 2015 02:20:24 +0200 Subject: [PATCH] Modify button generation to submit parameters as POST Fixes #20141 --- bugnote_view_inc.php | 24 ++++++++++++++++++++---- 1 file changed, 20 insertions(+), 4 deletions(-) diff --git a/bugnote_view_inc.php b/bugnote_view_inc.php index 0cd2036a01..d24fa10c46 100644 --- a/bugnote_view_inc.php +++ b/bugnote_view_inc.php @@ -219,20 +219,36 @@ # show edit button if the user is allowed to edit this bugnote if( $t_can_edit_bugnote ) { - print_button( 'bugnote_edit_page.php?bugnote_id='.$t_bugnote->id, lang_get( 'bugnote_edit_link' ), null, OFF ); + print_button( + 'bugnote_edit_page.php', + lang_get( 'bugnote_edit_link' ), + array( 'bugnote_id' => $t_bugnote->id ), + OFF ); } # show delete button if the user is allowed to delete this bugnote if( $t_can_delete_bugnote ) { - print_button( 'bugnote_delete.php?bugnote_id='.$t_bugnote->id, lang_get( 'delete_link' ), null, $t_security_token_delete ); + print_button( + 'bugnote_delete.php', + lang_get( 'delete_link' ), + array( 'bugnote_id' => $t_bugnote->id ), + $t_security_token_delete ); } # show make public or make private button if the user is allowed to change the view state of this bugnote if( $t_can_change_view_state ) { if( VS_PRIVATE == $t_bugnote->view_state ) { - print_button( 'bugnote_set_view_state.php?private=0&bugnote_id=' . $t_bugnote->id, lang_get( 'make_public' ), null, $t_security_token_state ); + print_button( + 'bugnote_set_view_state.php', + lang_get( 'make_public' ), + array( 'private' => '0', 'bugnote_id' => $t_bugnote->id ), + $t_security_token_state ); } else { - print_button( 'bugnote_set_view_state.php?private=1&bugnote_id=' . $t_bugnote->id, lang_get( 'make_private' ), null, $t_security_token_state ); + print_button( + 'bugnote_set_view_state.php', + lang_get( 'make_private' ), + array( 'private' => '1', 'bugnote_id' => $t_bugnote->id ), + $t_security_token_state ); } } }