You are here

function fb_canvas_secondary_links in Drupal for Facebook 5.2

Same name and namespace in other branches
  1. 5 fb_canvas.module \fb_canvas_secondary_links()

File

./fb_canvas.module, line 409
This module provides some app-specific navigation to facebook apps.

Code

function fb_canvas_secondary_links() {
  global $fb_app;
  if ($fb_app) {
    $fb_app_data = fb_app_get_data($fb_app);
    $fb_canvas_data = $fb_app_data['fb_canvas'];
    $mid1 = $fb_canvas_data['primary_links'];
    $mid2 = $fb_canvas_data['secondary_links'];
  }
  if ($mid2) {
    if ($mid2 == $mid1) {
      return menu_primary_links(2, $mid2);
    }
    else {
      return menu_primary_links(1, $mid2);
    }
  }
  else {
    return menu_secondary_links();
  }
}