mirror of
https://git.friendi.ca/friendica/friendica-addons.git
synced 2025-07-07 00:48:55 +00:00
Needed changes for a changed core function
This commit is contained in:
parent
37094047a1
commit
4f5390c09e
4 changed files with 10 additions and 10 deletions
|
@ -357,12 +357,12 @@ function appnet_create_entities($a, $b, $postdata) {
|
|||
$start = $pos + 1;
|
||||
}
|
||||
|
||||
if (isset($postdata["url"]) AND isset($postdata["title"])) {
|
||||
if (isset($postdata["url"]) AND isset($postdata["title"]) AND ($postdata["type"] != "photo")) {
|
||||
$postdata["title"] = shortenmsg($postdata["title"], 90);
|
||||
$max = 256 - strlen($postdata["title"]);
|
||||
$text = shortenmsg($text, $max);
|
||||
$text .= "\n[".$postdata["title"]."](".$postdata["url"].")";
|
||||
} elseif (isset($postdata["url"])) {
|
||||
} elseif (isset($postdata["url"]) AND ($postdata["type"] != "photo")) {
|
||||
$postdata["url"] = short_link($postdata["url"]);
|
||||
$max = 240;
|
||||
$text = shortenmsg($text, $max);
|
||||
|
@ -524,7 +524,7 @@ function appnet_send(&$a,&$b) {
|
|||
"value" => $attached_data
|
||||
);
|
||||
|
||||
if (isset($post["url"]) AND !isset($post["title"])) {
|
||||
if (isset($post["url"]) AND !isset($post["title"]) AND ($post["type"] != "photo")) {
|
||||
$display_url = str_replace(array("http://www.", "https://www."), array("", ""), $post["url"]);
|
||||
$display_url = str_replace(array("http://", "https://"), array("", ""), $display_url);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue