function theme_webform_display_file in Webform 7.3
Same name and namespace in other branches
- 6.3 components/file.inc \theme_webform_display_file()
- 7.4 components/file.inc \theme_webform_display_file()
Format the output of text data for this component.
1 theme call to theme_webform_display_file()
- _webform_display_file in components/
file.inc - Implements _webform_display_component().
File
- components/
file.inc, line 388 - Webform module file component.
Code
function theme_webform_display_file($variables) {
$element = $variables['element'];
$file = $element['#value'];
$url = !empty($file) ? webform_file_url($file->uri) : t('no upload');
return !empty($file) ? $element['#format'] == 'text' ? $url : l($file->filename, $url) : ' ';
}