Commit cad28df2 authored by Gerhard Killesreiter's avatar Gerhard Killesreiter

#56089, $form['#redirect'] shouldn't be clobbered by the _submit return...

#56089, $form['#redirect'] shouldn't be clobbered by the _submit return value., second try, patch by chx
parent fc7f5aff
......@@ -126,6 +126,9 @@ function drupal_get_form($form_id, &$form, $callback = NULL) {
if (is_array($goto)) {
call_user_func_array('drupal_goto', $redirect);
}
elseif (!isset($goto)) {
drupal_goto($_GET['q']);
}
else {
drupal_goto($goto);
}
......
......@@ -55,7 +55,7 @@ function system_perm() {
*/
function system_elements() {
// Top level form
$type['form'] = array('#method' => 'post', '#action' => request_uri(), '#redirect' => $_GET['q']);
$type['form'] = array('#method' => 'post', '#action' => request_uri());
// Inputs
$type['checkbox'] = array('#input' => TRUE, '#return_value' => 1);
......
......@@ -55,7 +55,7 @@ function system_perm() {
*/
function system_elements() {
// Top level form
$type['form'] = array('#method' => 'post', '#action' => request_uri(), '#redirect' => $_GET['q']);
$type['form'] = array('#method' => 'post', '#action' => request_uri());
// Inputs
$type['checkbox'] = array('#input' => TRUE, '#return_value' => 1);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment