nortmas
6/10/2014 - 3:18 PM

Panels get current page display

function menu_callback() {
  module_load_include('inc', 'page_manager', 'plugins/tasks/page');
  return page_manager_page_execute('search_page');
}
/**
 * Return html for panels region.
 *
 * @ingroup themeable
 */
function [theme_name]_panels_default_style_render_region($vars) {
}

/**
 * Preprocess variables for panels-pane.tpl.php.
 */
function [theme_name]_preprocess_panels_pane(&$variables) {
}

/**
 * Preprocess variables for panel layout
 */
function [theme_name]_preprocess_[layout_name](&$vars) {
  aa_preprocess_aa_master($vars);
}
$panel = panels_get_current_page_display();
if (isset($panel->layout)) {
  $layout = $panel->layout;
}


// display ctools CT 
ctools_include('content');
if ($pane = ctools_content_render('aa_webcall_block', $subtype, $conf)) {
  $block->content['webcall'] = array(
    '#markup' => is_array($pane->content) ? render($pane->content) : $pane->content,
  );
}