X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=src%2FContent%2FText%2FMarkdownParser.php;h=111acedd1ec2a755a9be402241b54391a5f7a2b6;hb=d9cd2f5bca54f56022cef5131b5ee35199f6820e;hp=fa1d166ec3a3456af0c074209362528b4a9d5978;hpb=81e1e859a3bff4ebd61f2e2b61c2ff98ed982a62;p=friendica.git diff --git a/src/Content/Text/MarkdownParser.php b/src/Content/Text/MarkdownParser.php index fa1d166ec3..111acedd1e 100644 --- a/src/Content/Text/MarkdownParser.php +++ b/src/Content/Text/MarkdownParser.php @@ -1,18 +1,38 @@ -. + * + */ + +namespace Friendica\Content\Text; + +use Friendica\Util\Strings; +use Michelf\MarkdownExtra; + +class MarkdownParser extends MarkdownExtra +{ + protected function doAutoLinks($text) + { + $text = parent::doAutoLinks($text); + + $text = preg_replace_callback(Strings::autoLinkRegEx(), + array($this, '_doAutoLinks_url_callback'), $text); + + return $text; + } } \ No newline at end of file