function fb_connect_theme_user_picture_override in Drupal for Facebook 6.2
Same name and namespace in other branches
- 6.3 fb_connect.module \fb_connect_theme_user_picture_override()
- 7.3 fb_connect.module \fb_connect_theme_user_picture_override()
Our replacement for theme('user_picture', ...)
1 string reference to 'fb_connect_theme_user_picture_override'
- fb_connect_theme_registry_alter in ./
fb_connect.module - Implementation of hook_theme_registry_alter().
File
- ./
fb_connect.module, line 758 - Support for Facebook Connect features
Code
function fb_connect_theme_user_picture_override($account) {
// Markup without fb_connect.
$orig = theme('fb_connect_user_picture_orig', $account);
// Make no changes to FBML pages.
if (fb_is_fbml_canvas()) {
return $orig;
}
// Respect Drupal's profile pic, if uploaded.
if (isset($account->picture) && $account->picture) {
return $orig;
}
if ($fbu = fb_get_object_fbu($account)) {
$output = theme('fb_connect_fbml_user_picture', $fbu, $account, $orig);
}
else {
$output = $orig;
}
return $output;
}