function asset_field_formatter in Asset 5
Same name and namespace in other branches
- 5.2 modules/asset_content.inc \asset_field_formatter()
- 6 modules/asset_content.inc \asset_field_formatter()
Prepare an individual item for viewing in a browser.
File
- modules/
asset_content.inc, line 60
Code
function asset_field_formatter($field, $item, $formatter, $node) {
$teaser = arg(0) == 'node' && is_numeric(arg(1)) ? FALSE : TRUE;
if (!empty($item['aid'])) {
return asset_lightbox(array(
$item,
), FALSE, $teaser);
}
}