function file_entity_is_page in File Entity (fieldable files) 7.2
Same name and namespace in other branches
- 7.3 file_entity.module \file_entity_is_page()
Returns whether the current page is the full page view of the passed-in file.
Parameters
$file: A file object.
2 calls to file_entity_is_page()
- file_view in ./
file_entity.file_api.inc - Generate an array for rendering the given file.
- template_preprocess_file_entity in ./
file_entity.module - Process variables for file_entity.tpl.php
File
- ./
file_entity.module, line 1505 - Extends Drupal file entities to be fieldable and viewable.
Code
function file_entity_is_page($file) {
$page_file = menu_get_object('file', 1);
return !empty($page_file) ? $page_file->fid == $file->fid : FALSE;
}