class twitter_views_handler_field_profile_image in Twitter 6.4
Same name and namespace in other branches
- 6.5 twitter_views_field_handlers.inc \twitter_views_handler_field_profile_image
- 6.2 twitter_views_field_handlers.inc \twitter_views_handler_field_profile_image
- 6.3 twitter_views_field_handlers.inc \twitter_views_handler_field_profile_image
- 7.6 twitter_views_field_handlers.inc \twitter_views_handler_field_profile_image
- 7.3 twitter_views_field_handlers.inc \twitter_views_handler_field_profile_image
- 7.4 twitter_views_field_handlers.inc \twitter_views_handler_field_profile_image
- 7.5 twitter_views_field_handlers.inc \twitter_views_handler_field_profile_image
Field handler to provide simple renderer that turns a URL into a clickable link.
Hierarchy
- class \twitter_views_handler_field_profile_image extends \views_handler_field
Expanded class hierarchy of twitter_views_handler_field_profile_image
1 string reference to 'twitter_views_handler_field_profile_image'
- twitter_views_data in ./
twitter.views.inc - Implementation of hook_views_data()
File
- ./
twitter_views_field_handlers.inc, line 60
View source
class twitter_views_handler_field_profile_image extends views_handler_field {
// Ensure we have the account name field to be used
// as alt and title attributes of the image.
function construct() {
parent::construct();
$this->additional_fields['name'] = 'name';
}
function query() {
parent::query();
$this
->ensure_my_table();
$this
->add_additional_fields();
}
function render($values) {
$name = $values->{$this->aliases['name']};
$value = $values->{$this->field_alias};
return theme('image', $value, $name, t("@name's twitter picture", array(
'@name' => $name,
)), array(), FALSE);
}
}