function ds_panels_layout_change in Display Suite 7
Submit callback: Redirect to change the layout.
1 string reference to 'ds_panels_layout_change'
- ds_panels_layout in modules/
ds_extras/ ds_extras.panels.inc - Return the Panels layout settings form.
File
- modules/
ds_extras/ ds_extras.panels.inc, line 668 - Administrative functions for DS panels.
Code
function ds_panels_layout_change($form, &$form_state) {
$destination = array();
// In case there's a redirect, kill it and append it to the redirect.
if (isset($_GET['destination']) && !empty($_GET['destination'])) {
$destination = array(
'query' => array(
'destination' => $_GET['destination'],
),
);
unset($_GET['destination']);
}
$form_state['redirect'] = array(
$_GET['q'] . '/' . $form_state['values']['layout'],
$destination,
);
}