You are here

function panels_common_save_context in Panels 5.2

Same name and namespace in other branches
  1. 6.2 includes/ \panels_common_save_context()
3 calls to panels_common_save_context()
panels_mini_context_form_submit in panels_mini/panels_mini.module
Process submission of the mini panel edit form.
panels_node_context_form_submit in panels_node/panels_node.module
Process submission of the panel node edit form.
panels_page_context_form_submit in panels_page/
Process submission of the panel page edit form.


includes/, line 1434
Functions used by more than one panels client module.


function panels_common_save_context($type, &$ref, $form_values) {

  // Organize arguments
  $ref = array();
  if (isset($form_values[$type . '_order']) && $form_values[$type . '_order'] !== '') {
    foreach (explode(',', $form_values[$type . '_order']) as $position) {

      // We retain the original position here because we need argument IDs.
      $ref[$position] = $form_values[$type . 's'][$position];