function theme_ctools_collapsible

Render a collapsible div.

Parameters

$handle: Text to put in the handle/title area of the div.

$content: Text to put in the content area of the div, this is what will get collapsed.

$collapsed: If true, this div will start out collapsed.

2 theme calls to theme_ctools_collapsible()
ctools_ajax_sample_page in ctools_ajax_sample/ctools_ajax_sample.module
Page callback to display links and render a container for AJAX stuff.
page_manager_render_operations in page_manager/page_manager.admin.inc
Render an operations array.

File

includes/collapsible.theme.inc, line 37

Code

function theme_ctools_collapsible($vars) {
    ctools_add_js('collapsible-div');
    ctools_add_css('collapsible-div');
    $class = $vars['collapsed'] ? ' ctools-collapsed' : '';
    $output = '<div class="ctools-collapsible-container' . $class . '">';
    $output .= '<div class="ctools-collapsible-handle">' . $vars['handle'] . '</div>';
    $output .= '<div class="ctools-collapsible-content">' . $vars['content'] . '</div>';
    $output .= '</div>';
    return $output;
}