aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorzotlabs <mike@macgirvin.com>2016-12-19 14:35:13 -0800
committerzotlabs <mike@macgirvin.com>2016-12-19 14:35:13 -0800
commit350627988eb7813dac69450ff97f03a33e70d9f2 (patch)
tree6924d4d900df0958bfebf01775242cee456d0a85
parent468fb3c77a60fe38a021502bce5ca6a4e4c211a4 (diff)
downloadvolse-hubzilla-350627988eb7813dac69450ff97f03a33e70d9f2.tar.gz
volse-hubzilla-350627988eb7813dac69450ff97f03a33e70d9f2.tar.bz2
volse-hubzilla-350627988eb7813dac69450ff97f03a33e70d9f2.zip
zidify private mail
-rw-r--r--Zotlabs/Module/Mail.php11
-rw-r--r--include/text.php1
2 files changed, 6 insertions, 6 deletions
diff --git a/Zotlabs/Module/Mail.php b/Zotlabs/Module/Mail.php
index 2a8407910..459ce5acf 100644
--- a/Zotlabs/Module/Mail.php
+++ b/Zotlabs/Module/Mail.php
@@ -47,8 +47,7 @@ class Mail extends \Zotlabs\Web\Controller {
$body = trim(str_replace($match[1],'',$body));
}
}
-
- echo json_encode(['preview' => smilies(bbcode($body))]);
+ echo json_encode(['preview' => zidify_links(smilies(bbcode($body)))]);
killme();
}
@@ -110,6 +109,8 @@ class Mail extends \Zotlabs\Web\Controller {
require_once('include/text.php');
linkify_tags($a, $body, local_channel());
+ // I don't think this is used any more.
+
if($preview) {
$mail = [
'mailbox' => 'outbox',
@@ -118,8 +119,8 @@ class Mail extends \Zotlabs\Web\Controller {
'from_name' => $channel['xchan_name'],
'from_url' => $channel['xchan_url'],
'from_photo' => $channel['xchan_photo_s'],
- 'subject' => smilies(bbcode($subject)),
- 'body' => smilies(bbcode($body)),
+ 'subject' => zidify_links(smilies(bbcode($subject))),
+ 'body' => zidify_links(smilies(bbcode($body))),
'attachments' => '',
'can_recall' => false,
'is_recalled' => '',
@@ -369,7 +370,7 @@ class Mail extends \Zotlabs\Web\Controller {
'to_url' => chanlink_hash($message['to_xchan']),
'to_photo' => $message['to']['xchan_photo_s'],
'subject' => $message['title'],
- 'body' => smilies(bbcode($message['body'])),
+ 'body' => zidify_links(smilies(bbcode($message['body']))),
'attachments' => $s,
'delete' => t('Delete message'),
'dreport' => t('Delivery report'),
diff --git a/include/text.php b/include/text.php
index 593822bc7..d6151d8ef 100644
--- a/include/text.php
+++ b/include/text.php
@@ -3088,7 +3088,6 @@ function cleanup_bbcode($body) {
$body = preg_replace_callback('/\[\$b64url(.*?)\[\/(url)\]/ism','\red_unescape_codeblock',$body);
$body = preg_replace_callback('/\[\$b64code(.*?)\[\/(code)\]/ism','\red_unescape_codeblock',$body);
-
// fix any img tags that should be zmg
$body = preg_replace_callback('/\[img(.*?)\](.*?)\[\/img\]/ism','\red_zrlify_img_callback',$body);