aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/includes/mcp
diff options
context:
space:
mode:
authorDavid M <davidmj@users.sourceforge.net>2006-08-11 21:52:46 +0000
committerDavid M <davidmj@users.sourceforge.net>2006-08-11 21:52:46 +0000
commit86f3d738a0efbf5c50bdf112841aba2c8b859e85 (patch)
tree6c7c34285132704577420d8f6b56545523018c71 /phpBB/includes/mcp
parent9086adad3c5fb9454a6df9149fb3f4ab7987b8ef (diff)
downloadforums-86f3d738a0efbf5c50bdf112841aba2c8b859e85.tar
forums-86f3d738a0efbf5c50bdf112841aba2c8b859e85.tar.gz
forums-86f3d738a0efbf5c50bdf112841aba2c8b859e85.tar.bz2
forums-86f3d738a0efbf5c50bdf112841aba2c8b859e85.tar.xz
forums-86f3d738a0efbf5c50bdf112841aba2c8b859e85.zip
so.... what does this thing do?
well, the super fast, ultra efficient, massively huge BBCode handling system was implemented differently on each DBMS. Although this provided the best performance, the solution was a bit hacky. So what does this new thing do? We use base64 encoding to make everything nice and shiny, it turns into nice, safe characters that we can just jam into varchars on essentially any database. This has two implications: we must decode every bitfield we get AND we have slightly fewer IDs to work with. It goes down from 2040 BBCodes to 1512. We lose like a quarter of them :P P.S. I hope nothing broke :P git-svn-id: file:///svn/phpbb/trunk@6263 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB/includes/mcp')
-rw-r--r--phpBB/includes/mcp/mcp_main.php2
-rw-r--r--phpBB/includes/mcp/mcp_topic.php2
-rwxr-xr-xphpBB/includes/mcp/mcp_warn.php2
3 files changed, 3 insertions, 3 deletions
diff --git a/phpBB/includes/mcp/mcp_main.php b/phpBB/includes/mcp/mcp_main.php
index 9125ae55b1..ce0c47941d 100644
--- a/phpBB/includes/mcp/mcp_main.php
+++ b/phpBB/includes/mcp/mcp_main.php
@@ -886,7 +886,7 @@ function mcp_fork_topic($topic_ids)
'post_checksum' => (string) $row['post_checksum'],
'post_encoding' => (string) $row['post_encoding'],
'post_attachment' => (int) $row['post_attachment'],
- 'bbcode_bitfield' => (int) $row['bbcode_bitfield'],
+ 'bbcode_bitfield' => $row['bbcode_bitfield'],
'bbcode_uid' => (string) $row['bbcode_uid'],
'post_edit_time' => (int) $row['post_edit_time'],
'post_edit_count' => (int) $row['post_edit_count'],
diff --git a/phpBB/includes/mcp/mcp_topic.php b/phpBB/includes/mcp/mcp_topic.php
index b2c3e21170..75dd9ea2e2 100644
--- a/phpBB/includes/mcp/mcp_topic.php
+++ b/phpBB/includes/mcp/mcp_topic.php
@@ -92,7 +92,7 @@ function mcp_topic_view($id, $mode, $action)
while ($row = $db->sql_fetchrow($result))
{
$rowset[] = $row;
- $bbcode_bitfield = $bbcode_bitfield | $row['bbcode_bitfield'];
+ $bbcode_bitfield = $bbcode_bitfield | base64_decode($row['bbcode_bitfield']);
}
$db->sql_freeresult($result);
diff --git a/phpBB/includes/mcp/mcp_warn.php b/phpBB/includes/mcp/mcp_warn.php
index 87ed6e93c8..bc428570ab 100755
--- a/phpBB/includes/mcp/mcp_warn.php
+++ b/phpBB/includes/mcp/mcp_warn.php
@@ -416,7 +416,7 @@ function add_warning($userrow, $warning, $send_pm = true, $post_id = 0)
'enable_smilies' => true,
'enable_urls' => false,
'icon_id' => 0,
- 'bbcode_bitfield' => (int) $message_parser->bbcode_bitfield,
+ 'bbcode_bitfield' => $message_parser->bbcode_bitfield,
'bbcode_uid' => $message_parser->bbcode_uid,
'message' => $message_parser->message,
'address_list' => array('u' => array($userrow['user_id'] => 'to')),