How can I display a picture from a field as the user picture rather than the drupal default with user-picture.tpl.php?
I don't think $user-&gt;field_profile_picture['und'][0]['filename'] would be set by default, you normally only get the fid column (this does vary depending on context, but you should always get the fid column either way).

This sort of code always works for me:

if (!empty($user-&gt;field_profile_picture[LANGUAGE_NONE][0]['fid'])) {
  // Load the file
  $file = file_load($user-&gt;field_profile_picture[LANGUAGE_NONE][0]['fid']);

  // Note the style name is "profile_picture" as explained in your question,
  // not "profile_pic" which was in your original code
  echo theme('image_style', array('style_name' =&gt; 'profile_picture', 'path' =&gt; $file-&gt;uri));
}


If you're worried about the extra overhead involved with potentially loading the file twice, don't be, Drupal caches the object the first time round.

It the above doesn't work it's likely that the $user object is not fully loaded and so the fields haven't been attached. If that's the case, load the user like this:

$account = user_load($user-&gt;uid);


And then use the $account object to test for the field value.