summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authoruckelman <uckelman@nomic.net>2010-04-25 20:48:44 +0000
committeruckelman <uckelman@nomic.net>2010-04-25 20:48:44 +0000
commitbc6a9a13842f53302333ee247a0450f6bb3fab1a (patch)
tree26a2e3180f8fb6e3ac1099747e62b3fdb915191e /src
parent99779d0c5982c7d0caaed2bf89b05404c01b8fe3 (diff)
Use BBCodeParser.
git-svn-id: https://vassalengine.svn.sourceforge.net/svnroot/vassalengine/site-src/trunk@6754 67b53d14-2c14-4ace-a08f-0dab2b34000c
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