Matthew Barbour ac6ded877f Added dependency support for extensions
Separated a few extensions that had multiple extension classes in the same file
2019-08-07 16:32:44 -05:00

22 lines
398 B
PHP

<?php
/**
* Class Emoticons
*/
class Emoticons extends FormatterExtension
{
public function format(string $text): string
{
$data_href = get_base_href();
$text = preg_replace("/:([a-z]*?):/s", "<img src='$data_href/ext/emoticons/default/\\1.gif'>", $text);
return $text;
}
public function strip(string $text): string
{
return $text;
}
}