The src for the picture was wrong:

Only local images are allowed.

In gravatar_get_account_user_picture I removed file_create_url and just returned $account->picture, it's a relative link after all, and now it works.

Comments

dsego’s picture

Wow, such a great commenting system...

This is the problem. The user picture had the wrong src

<img src="//sites/files/pictures/picture-19.jpg" alt="" title="">

When you remove the call to file_create_url and just return the pic it gets displayed properly.
Why call file_create_url anyway, if Drupal already outputs a relative link.

function _gravatar_get_account_user_picture($account) {
  if (!empty($account->picture) && file_exists($account->picture)) {
    // If the user has an uploaded picture, use it first.
    //return file_create_url($account->picture);
    return $account->picture;
  }

Narno’s picture

Assigned: Unassigned » Narno
Narno’s picture

Status: Active » Postponed (maintainer needs more info)

Why call file_create_url anyway, if Drupal already outputs a relative link.

Because Drupal 6 works like that by default:

// user.module / template_preprocess_user_picture(&$variables) / line 816
if (!empty($account->picture) && file_exists($account->picture)) {
  $picture = file_create_url($account->picture);
}

Can you give more details about your "strange" URL?