diff options
author | Thomas Willingham <founder@kakste.com> | 2012-03-26 20:17:01 +0100 |
---|---|---|
committer | Thomas Willingham <founder@kakste.com> | 2012-03-26 20:17:01 +0100 |
commit | 286c230fa858b7b1fead9c3ff722f6b1b9478d01 (patch) | |
tree | 463f0d075f9593a4d513aa91e08ebc896b00779a /include/text.php | |
parent | 64a2b00cdc97e40ac8e9dc8f0b9cdc5d78cdf2c2 (diff) | |
parent | 0a3f2bdd5bc51d7fc642f431843a5b13287ae94e (diff) | |
download | volse-hubzilla-286c230fa858b7b1fead9c3ff722f6b1b9478d01.tar.gz volse-hubzilla-286c230fa858b7b1fead9c3ff722f6b1b9478d01.tar.bz2 volse-hubzilla-286c230fa858b7b1fead9c3ff722f6b1b9478d01.zip |
Merge remote-tracking branch 'main/master'
Diffstat (limited to 'include/text.php')
-rw-r--r-- | include/text.php | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/include/text.php b/include/text.php index 527f3a344..6f66cef65 100644 --- a/include/text.php +++ b/include/text.php @@ -712,6 +712,7 @@ function smilies($s, $sample = false) { ';-)', ':-(', ':-P', + ':-p', ':-"', ':-"', ':-x', @@ -745,6 +746,7 @@ function smilies($s, $sample = false) { '<img src="' . $a->get_baseurl() . '/images/smiley-wink.gif" alt=";-)" />', '<img src="' . $a->get_baseurl() . '/images/smiley-frown.gif" alt=":-(" />', '<img src="' . $a->get_baseurl() . '/images/smiley-tongue-out.gif" alt=":-P" />', + '<img src="' . $a->get_baseurl() . '/images/smiley-tongue-out.gif" alt=":-p" />', '<img src="' . $a->get_baseurl() . '/images/smiley-kiss.gif" alt=":-\"" />', '<img src="' . $a->get_baseurl() . '/images/smiley-kiss.gif" alt=":-\"" />', '<img src="' . $a->get_baseurl() . '/images/smiley-kiss.gif" alt=":-x" />', @@ -1336,3 +1338,16 @@ function file_tag_unsave_file($uid,$item,$file) { function normalise_openid($s) { return trim(str_replace(array('http://','https://'),array('',''),$s),'/'); } + + +function undo_post_tagging($s) { + $matches = null; + $cnt = preg_match_all('/([@#])\[url=(.*?)\](.*?)\[\/url\]/ism',$s,$matches,PREG_SET_ORDER); + if($cnt) { + foreach($matches as $mtch) { + $s = str_replace($mtch[0], $mtch[1] . $mtch[3],$s); + } + } + return $s; +} + |