You are here

function theme_profile_block in Drupal 4

Same name and namespace in other branches
  1. 5 modules/profile/profile.module \theme_profile_block()
1 theme call to theme_profile_block()
profile_block in modules/profile.module
Implementation of hook_block().

File

modules/profile.module, line 740
Support for configurable user profiles.

Code

function theme_profile_block($account, $fields = array()) {
  $output .= theme('user_picture', $account);
  foreach ($fields as $field) {
    if ($field->value) {
      if ($field->type == 'checkbox') {
        $output .= "<p>{$field->value}</p>\n";
      }
      else {
        $output .= '<p><strong>' . check_plain($field->title) . "</strong><br />{$field->value}</p>\n";
      }
    }
  }
  return $output;
}