function fb_fbml_menu_local_tasks in Drupal for Facebook 6.2
File
- themes/fb_fbml/template.php, line 146
- Logic needed for FBML theme.
Code
function fb_fbml_menu_local_tasks() {
global $fb;
if ($fb && $fb
->in_fb_canvas()) {
$output = '';
if ($primary = menu_primary_local_tasks()) {
$output .= "<fb:tabs>\n" . $primary . "</fb:tabs>\n";
}
if ($secondary = menu_secondary_local_tasks()) {
$pattern = '|<fb:tab-item href="([^"]*)" title="([^"]*)"([^>]*)>([^<]*)</fb:tab-item>|';
$replace = '<li $3><a href="$1">$4</a></li>';
$secondary = preg_replace($pattern, $replace, $secondary);
$output .= "<ul class=\"tabs secondary\">\n" . $secondary . "</ul>\n";
}
}
else {
$output = theme_menu_local_tasks();
}
return $output;
}