Example #1
0
File: output.php Project: elgg/elgg
/**
 * Takes a string and turns any email addresses into formatted links
 *
 * @param string $text The input string
 *
 * @return string The output string with formatted links
 *
 * @since 2.3
 */
function elgg_parse_emails($text)
{
    $linkify = new \Misd\Linkify\Linkify();
    return $linkify->processEmails($text, ['attr' => ['rel' => 'nofollow']]);
}