function _AdvisingScreen::draw_menu_item

4.x _AdvisingScreen.php _AdvisingScreen::draw_menu_item($url, $target, $icon_img, $title, $description = "")
5.x _AdvisingScreen.php _AdvisingScreen::draw_menu_item($url, $target, $icon_img, $title, $description = "")

Simply builds a single menu item.

Return value

string

1 call to _AdvisingScreen::draw_menu_item()
_AdvisingScreen::draw_menu_items in classes/_AdvisingScreen.php
Uses the draw_menu_item method to draw the HTML for all the supplied menu items, assuming the user has permission to view them.

File

classes/_AdvisingScreen.php, line 197

Class

_AdvisingScreen

Code

function draw_menu_item($url, $target, $icon_img, $title, $description = "") {

  $rtn = "";

  if (!$description) {
    $extra_class = "fp-menu-item-tight";
  }

  $rtn .= "<div class='fp-menu-item $extra_class'>
            <div class='fp-menu-item-link-line'>
              <a href='$url' target='$target'>$icon_img $title</a>
            </div>
            ";
  if ($description) {
    $rtn .= " <div class='fp-menu-item-description'>$description</div>";
  }
  $rtn .= "</div>";

  return $rtn;
}