Merge branch 'master' of git://github.com/derflocki/php-markdown into extra
This commit is contained in:
commit
4742d28fab
1 changed files with 7 additions and 0 deletions
|
|
@ -1479,9 +1479,16 @@ class Markdown_Parser {
|
|||
>
|
||||
}xi',
|
||||
array(&$this, '_doAutoLinks_email_callback'), $text);
|
||||
$text = preg_replace_callback('{<(tel:([^\'">\s]+))>}i',array(&$this, '_doAutoLinks_tel_callback'), $text);
|
||||
|
||||
return $text;
|
||||
}
|
||||
function _doAutoLinks_tel_callback($matches) {
|
||||
$url = $this->encodeAttribute($matches[1]);
|
||||
$tel = $this->encodeAttribute($matches[2]);
|
||||
$link = "<a href=\"$url\">$tel</a>";
|
||||
return $this->hashPart($link);
|
||||
}
|
||||
function _doAutoLinks_url_callback($matches) {
|
||||
$url = $this->encodeAttribute($matches[1]);
|
||||
$link = "<a href=\"$url\">$url</a>";
|
||||
|
|
|
|||
Loading…
Reference in a new issue