| 1 |
<?php
|
| 2 |
// $Id$
|
| 3 |
|
| 4 |
/**
|
| 5 |
* @file
|
| 6 |
* Handling for the poster's picture in Views.
|
| 7 |
*/
|
| 8 |
|
| 9 |
/**
|
| 10 |
* Shows the profile picture for the user who posted the status.
|
| 11 |
*/
|
| 12 |
class facebook_status_views_handler_field_poster_pic extends views_handler_field {
|
| 13 |
function render($values) {
|
| 14 |
if ($values->facebook_status_pid) {
|
| 15 |
$pid = $values->facebook_status_pid;
|
| 16 |
}
|
| 17 |
else if ($values->facebook_status_sid) {
|
| 18 |
$status = facebook_status_load($values->facebook_status_sid);
|
| 19 |
$pid = $status->pid;
|
| 20 |
}
|
| 21 |
return facebook_status_display_user_picture(user_load(array('uid' => $pid)));
|
| 22 |
}
|
| 23 |
}
|