summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/F2M.php9
1 files changed, 3 insertions, 6 deletions
diff --git a/src/F2M.php b/src/F2M.php
index 8e65537..445e047 100644
--- a/src/F2M.php
+++ b/src/F2M.php
@@ -21,6 +21,7 @@ function send_post_to_lists($config, $user, $mode, $data, $post_data) {
require_once('Mail.php');
+ require_once(__DIR__ . '/BBCodeParser.php');
require_once(__DIR__ . '/Bridge.php');
require_once(__DIR__ . '/PhpBB3.php');
require_once(__DIR__ . '/Util.php');
@@ -93,10 +94,8 @@ function send_post_to_lists($config, $user, $mode, $data, $post_data) {
}
# Build the message body
- $text = $data['message'];
- strip_bbcode($text, $data['bbcode_uid']);
- $text = htmlspecialchars_decode($text);
- $text = wordwrap($text, 72);
+ $parser = new BBCodeParser();
+ $text = $parser->parse($data['message'], $data['bbcode_uid']);
if ($mode == 'edit') {
$edit_notice = <<<EOF
@@ -110,8 +109,6 @@ EOF;
$headers['Subject'] = $edit_header . $headers['Subject'];
}
-# TODO: BBCode to Markdown (?)
-
# Build the bridge footer
$postURL = "$forumURL/viewtopic.php?p=$postId#p$postId";
$footer = <<<EOF