function fp_render_sub_tab_array

7.x theme.inc fp_render_sub_tab_array($tab_array)
6.x theme.inc fp_render_sub_tab_array($tab_array)
4.x theme.inc fp_render_sub_tab_array($tab_array)
5.x theme.inc fp_render_sub_tab_array($tab_array)

Similar to render_tab_array.

1 call to fp_render_sub_tab_array()
fp_display_page in includes/theme.inc
Output the contents of the $page variable to the screen. $page is an array containing details about the page, as well as its original menu item (router_item) definition.

File

includes/theme.inc, line 994

Code

function fp_render_sub_tab_array($tab_array) {
  global $current_student_id;

  $rtn = "";

  $rtn .= "<div class='sub-tabs'>";

  foreach ($tab_array as $tab) {
    $title = @$tab ["title"];
    $on_click = @$tab ["on_click"];
    $active = @$tab ["active"];
    $type = @$tab ["type"];

    $extra_class = "";
    if ($active) {
      $extra_class = "gradbutton-active";
    }

    if ($type == "link") {
      // Render as a standard link
      $rtn .= "<a href='javascript: $on_click' class='fp-sub-tab-link $extra_class'>$title</a>";
    }
    else {
      // Render as a button
      $rtn .= fp_render_button($title, $on_click, true, "", $extra_class);
    }

  }


  $rtn .= "</div>";

  return $rtn;
}