Elgg  Version 2.2
 All Classes Namespaces Files Functions Variables Pages
file.php
Go to the documentation of this file.
1 <?php
13 if (!empty($vars['value'])) {
14  echo elgg_echo('fileexists') . "<br />";
15 }
16 
17 $vars['class'] = (array) elgg_extract('class', $vars, []);
18 $vars['class'][] = 'elgg-input-file';
19 
20 $defaults = array(
21  'disabled' => false,
22  'type' => 'file'
23 );
24 
25 $vars = array_merge($defaults, $vars);
26 
27 echo elgg_format_element('input', $vars);
elgg_echo($message_key, $args=array(), $language="")
Given a message key, returns an appropriately translated full-text string.
Definition: languages.php:21
elgg_format_element($tag_name, array $attributes=array(), $text= '', array $options=array())
Format an HTML element.
Definition: output.php:218
$defaults
Definition: file.php:20
elgg_extract($key, $array, $default=null, $strict=true)
Checks for $array[$key] and returns its value if it exists, else returns $default.
Definition: elgglib.php:1310
if(!empty($vars['value'])) $vars['class']
Definition: file.php:17