{"action":"opened","issue":{"url":"https://api.github.com/repos/yiisoft/yii2/issues/9079","labels_url":"https://api.github.com/repos/yiisoft/yii2/issues/9079/labels{/name}","comments_url":"https://api.github.com/repos/yiisoft/yii2/issues/9079/comments","events_url":"https://api.github.com/repos/yiisoft/yii2/issues/9079/events","html_url":"https://github.com/yiisoft/yii2/issues/9079","id":94414005,"number":9079,"title":"Add Html::tel();","user":{"login":"skworden","id":2423551,"avatar_url":"https://avatars.githubusercontent.com/u/2423551?v=3","gravatar_id":"","url":"https://api.github.com/users/skworden","html_url":"https://github.com/skworden","followers_url":"https://api.github.com/users/skworden/followers","following_url":"https://api.github.com/users/skworden/following{/other_user}","gists_url":"https://api.github.com/users/skworden/gists{/gist_id}","starred_url":"https://api.github.com/users/skworden/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/skworden/subscriptions","organizations_url":"https://api.github.com/users/skworden/orgs","repos_url":"https://api.github.com/users/skworden/repos","events_url":"https://api.github.com/users/skworden/events{/privacy}","received_events_url":"https://api.github.com/users/skworden/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-07-10T23:40:50Z","updated_at":"2015-07-10T23:40:50Z","closed_at":null,"body":"With all of the other types of HTML helpers Yii2 has I think it's only fitting to have a tel: hyperlink type as well. \r\n\r\nIt is almost an exact copy of the mailto function.\r\n```/**\r\n     * Generates a tel hyperlink.\r\n     * @param string $text link body. It will NOT be HTML-encoded. Therefore you can pass in HTML code\r\n     * such as an image tag. If this is coming from end users, you should consider [[encode()]]\r\n     * it to prevent XSS attacks.\r\n     * @param string $tel telephone number. If this is null, the first parameter (telephone body) will be treated\r\n     * as the telephone number and used.\r\n     * @param array $options the tag options in terms of name-value pairs. These will be rendered as\r\n     * the attributes of the resulting tag. The values will be HTML-encoded using [[encode()]].\r\n     * If a value is null, the corresponding attribute will not be rendered.\r\n     * See [[renderTagAttributes()]] for details on how attributes are being rendered.\r\n     * @return string the generated mailto link\r\n     */\r\n    public static function tel($text, $tel = null, $options = []) {\r\n        $options['href'] = 'tel:' . ($tel === null ? $text : $tel);\r\n        return static::tag('a', $text, $options);\r\n    }"}}