Improve reshare format for Diaspora destinations
- Add link to original post in post time - Update optional bottom link label
This commit is contained in:
parent
fe8d5abe0a
commit
9cdae18101
|
@ -950,15 +950,19 @@ class BBCode extends BaseObject
|
||||||
$text = ($is_quote_share? '<br />' : '') . '<p>' . html_entity_decode('♲ ', ENT_QUOTES, 'UTF-8') . ' ' . $author_contact['addr'] . ': </p>' . "\n" . $content;
|
$text = ($is_quote_share? '<br />' : '') . '<p>' . html_entity_decode('♲ ', ENT_QUOTES, 'UTF-8') . ' ' . $author_contact['addr'] . ': </p>' . "\n" . $content;
|
||||||
break;
|
break;
|
||||||
case 3: // Diaspora
|
case 3: // Diaspora
|
||||||
$headline = '<p><b>' . html_entity_decode('♲ ', ENT_QUOTES, 'UTF-8') . $mention . ':</b></p>' . "\n";
|
|
||||||
|
|
||||||
if (stripos(Strings::normaliseLink($attributes['link']), 'http://twitter.com/') === 0) {
|
if (stripos(Strings::normaliseLink($attributes['link']), 'http://twitter.com/') === 0) {
|
||||||
$text = ($is_quote_share? '<hr />' : '') . '<p><a href="' . $attributes['link'] . '">' . $attributes['link'] . '</a></p>' . "\n";
|
$text = ($is_quote_share? '<hr />' : '') . '<p><a href="' . $attributes['link'] . '">' . $attributes['link'] . '</a></p>' . "\n";
|
||||||
} else {
|
} else {
|
||||||
|
$headline = '<p><b>♲ <a href="' . $attributes['profile'] . '">' . $attributes['author'] . '</a>:</b></p>' . "\n";
|
||||||
|
|
||||||
|
if (!empty($attributes['posted']) && !empty($attributes['link'])) {
|
||||||
|
$headline = '<p><b>♲ <a href="' . $attributes['profile'] . '">' . $attributes['author'] . '</a></b> - <a href="' . $attributes['link'] . '">' . $attributes['posted'] . ' GMT</a></p>' . "\n";
|
||||||
|
}
|
||||||
|
|
||||||
$text = ($is_quote_share? '<hr />' : '') . $headline . '<blockquote>' . trim($content) . '</blockquote>' . "\n";
|
$text = ($is_quote_share? '<hr />' : '') . $headline . '<blockquote>' . trim($content) . '</blockquote>' . "\n";
|
||||||
|
|
||||||
if ($attributes['link'] != '') {
|
if (empty($attributes['posted']) && !empty($attributes['link'])) {
|
||||||
$text .= '<p><a href="' . $attributes['link'] . '">[l]</a></p>' . "\n";
|
$text .= '<p><a href="' . $attributes['link'] . '">[Source]</a></p>' . "\n";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user