You are here

function theme_webform_mail_file in Webform 6.2

Same name and namespace in other branches
  1. 5.2 components/file.inc \theme_webform_mail_file()
  2. 5 components/file.inc \theme_webform_mail_file()

Format the output of emailed data for this component

Parameters

mixed $data: A string or array of the submitted data.

array $component: An array of information describing the component, directly correlating to the webform_component database schema.

Return value

Textual output to be included in the email.

File

components/file.inc, line 396
Webform module file component.

Code

function theme_webform_mail_file($data, $component) {
  $file = is_string($data) ? unserialize($data) : $data;
  $output = $component['name'] . ': ' . (!empty($file['filepath']) ? webform_file_url($file['filepath']) : '') . "\n";
  return $output;
}