I did a few tests and also the STK mod developer confirms that the topic author problem and the post count problem are not issues with the BBcode re-parse function of the STK but rather are issues with the message import tool.
-the post count issue is already there before running the re-parse tool
-the topic author problems also appears as soon as you edit one of the posts in a topic (without running the re-parse tool). The BBcode re-parse function just mass processes all posts and therefore brings out this issue on all topcis
If you are using this tool to import messages into a clean board you can try the SQL statements I posted earlier, after running the BBcode re-parse function, to fix the issues. But only on a clean board with no previous normal posts!
No doubt the SQL statements can be changed to only make the changes where needed but I am a complete SQL noob unfortunately.
Hopefully someone can take a look at the php code of this XML import tool again and make the necessary modifications to prevent these issues.
I suspect the issues are in this part of the code:
Code: Select all
// Store last post data in topic
$post_count = sizeof($topic_elm);
$sql_data = array(
'topic_first_post_id' => $first_msg_id,
'topic_last_post_id' => $msg_id,
'topic_last_post_time' => $msg_date,
'topic_last_view_time' => $msg_date,
'topic_last_poster_id' => $poster_data['user_id'],
'topic_last_poster_name' => $poster_name,
'topic_last_poster_colour' => (string)$poster_data['colour'],
'topic_last_post_subject' => (string)$msg_data['title'],
'topic_replies' => $post_count,
'topic_replies_real' => $post_count,
$sql = 'UPDATE ' . TOPICS_TABLE . '
SET ' . $db->sql_build_array('UPDATE', $sql_data) . '
WHERE topic_id = ' . $topic_id;
I've attached an updated version of the tool that incorporates the fixes from:
Although that last change doesn't seem to work (I imported a lot of topics with Danish characters and the topic titles still got truncated below 60 characters).
Install the 1.0.2 version from here:
and copy my attached version over the existing apc_import_messages.php in phpbb3/www/includes/acp
Let's call it version 1.0.4