]> git.mxchange.org Git - friendica.git/blobdiff - include/text.php
Merge branch 'pull'
[friendica.git] / include / text.php
index ba6c2531fbeb380734a9de600ad6e800d04a35ae..e0f38a3a0d4b8bf9ec53610459d7e0ca797f28b8 100644 (file)
@@ -481,7 +481,7 @@ function get_tags($s) {
        // Otherwise pull out single word tags. These can be @nickname, @first_last
        // and #hash tags.
 
-       if(preg_match_all('/([@#][^ \x0D\x0A,:?]+)([ \x0D\x0A,:?]|$)/',$s,$match)) {
+       if(preg_match_all('/([@#][^ \x0D\x0A,;:?]+)([ \x0D\x0A,;:?]|$)/',$s,$match)) {
                foreach($match[1] as $mtch) {
                        if(strstr($mtch,"]")) {
                                // we might be inside a bbcode color tag - leave it alone
@@ -787,6 +787,15 @@ function prepare_body($item,$attach = false) {
                $s .= '<div class="clear"></div></div>';
        }
 
+       $arr = explode(',',$item['tag']);
+       if(count($arr)) {
+               $s .= '<div class="body-tag">';
+               foreach($arr as $r) {
+                       $s .= bbcode($r) . ' ';
+               }
+               $s .= '</div>';
+       }
+
        $prep_arr = array('item' => $item, 'html' => $s);
        call_hooks('prepare_body_final', $prep_arr);
        return $prep_arr['html'];