mirror of
https://git.sekbaer.de/Friendica/friendica.git
synced 2025-06-11 01:24:27 +02:00
The title of bookmark links is now taken instead of the data that was fetched via oembed
This commit is contained in:
parent
25237c0929
commit
72eee45b92
2 changed files with 23 additions and 4 deletions
|
@ -939,7 +939,22 @@ function add_page_info_to_body($body, $texturl = false, $no_photos = false) {
|
|||
}
|
||||
|
||||
if ($matches)
|
||||
$body .= add_page_info($matches[1], $no_photos);
|
||||
$footer = add_page_info($matches[1], $no_photos);
|
||||
|
||||
// Remove the link from the body if the link is attached at the end of the post
|
||||
if (isset($footer) AND (trim($footer) != "") AND (strpos($footer, $matches[1]))) {
|
||||
$removedlink = trim(str_replace($matches[1], "", $body));
|
||||
if (strstr($body, $removedlink))
|
||||
$body = $removedlink;
|
||||
|
||||
$removedlink = trim(str_replace("[url]".$matches[1]."[/url]", "", $body));
|
||||
if (strstr($body, $removedlink))
|
||||
$body = $removedlink;
|
||||
}
|
||||
|
||||
// Add the page information to the bottom
|
||||
if (isset($footer) AND (trim($footer) != ""))
|
||||
$body .= $footer;
|
||||
|
||||
return $body;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue