Elgg  Version master
tel.php
Go to the documentation of this file.
1 <?php
8 $value = elgg_extract('value', $vars);
9 
10 echo elgg_view('output/url', [
11  'text' => $value,
12  'href' => "tel:{$value}",
13  'allowed_schemes' => ['tel'],
14 ]);
elgg_extract($key, $array, $default=null, bool $strict=true)
Checks for $array[$key] and returns its value if it exists, else returns $default.
Definition: elgglib.php:254
elgg_view(string $view, array $vars=[], string $viewtype= '')
Return a parsed view.
Definition: views.php:177
$value
Displays formatted telephone.
Definition: tel.php:8
$vars['class']
Elgg tel input Displays a tel input field.
Definition: tel.php:7