]> git.mxchange.org Git - friendica.git/blobdiff - include/bbcode.php
Merge pull request #3392 from Hypolite/issue/#3387
[friendica.git] / include / bbcode.php
index 1075d84ac82738468202b182cd8e0b9b660eb3fc..2715334e46b0712f39aa5e2f514eedc81599c81c 100644 (file)
@@ -63,7 +63,7 @@ function bb_attachment($Text, $simplehtml = false, $tryoembed = true) {
                        (similar_text($test1,$test2) / strlen($data["title"])) > 0.9)) {
                        $title2 = $data["url"];
                }
-               $text = sprintf('<a href="%s" title="%s" class="attachment thumbnail" rel="nofollow external">%s</a><br />',
+               $text = sprintf('<a href="%s" title="%s" class="attachment" rel="nofollow external">%s</a><br />',
                                $data["url"], $data["title"], $title2);
        } elseif (($simplehtml != 4) AND ($simplehtml != 0)) {
                $text = sprintf('<a href="%s" target="_blank">%s</a><br>', $data["url"], $data["title"]);
@@ -97,7 +97,7 @@ function bb_attachment($Text, $simplehtml = false, $tryoembed = true) {
                        }
                }
        }
-       return $data["text"] . $text . $data["after"];
+       return trim($data["text"].' '.$text.' '.$data["after"]);
 }
 
 function bb_remove_share_information($Text, $plaintext = false, $nolink = false) {
@@ -573,7 +573,7 @@ function GetProfileUsername($profile, $username, $compact = false, $getnetwork =
        $gplus = preg_replace("=https?://plus.google.com/(.*)=ism", "$1@plus.google.com", $profile);
        if ($gplus != $profile) {
                if ($getnetwork) {
-                       return NETWORK_GPLUS);
+                       return NETWORK_GPLUS;
                } elseif ($compact) {
                        return ($gplususername . " (" . $username . ")");
                } else {