|
@@ -438,6 +438,7 @@ class WordPressImport {
|
|
|
|
|
|
|
|
if (!empty($postIds)) {
|
|
if (!empty($postIds)) {
|
|
|
$placeholders = str_repeat('?,', count($postIds) - 1) . '?';
|
|
$placeholders = str_repeat('?,', count($postIds) - 1) . '?';
|
|
|
|
|
+ $this->log("Executing publication mapping query with " . count($postIds) . " post IDs");
|
|
|
$pubStmt = $this->targetDb->query("
|
|
$pubStmt = $this->targetDb->query("
|
|
|
SELECT id, wp_post_id FROM publications
|
|
SELECT id, wp_post_id FROM publications
|
|
|
WHERE wp_post_id IN ($placeholders)
|
|
WHERE wp_post_id IN ($placeholders)
|
|
@@ -476,6 +477,7 @@ class WordPressImport {
|
|
|
$parentId = null;
|
|
$parentId = null;
|
|
|
|
|
|
|
|
// Insert comment
|
|
// Insert comment
|
|
|
|
|
+ $this->log("Executing INSERT for comment: '{$wpComment['comment_content']}' (Post ID: {$wpPostId})");
|
|
|
$this->targetDb->query(
|
|
$this->targetDb->query(
|
|
|
"INSERT INTO comments (publication_id, parent_id, name, email, content, status, created_at, admin_reply, wp_comment_id)
|
|
"INSERT INTO comments (publication_id, parent_id, name, email, content, status, created_at, admin_reply, wp_comment_id)
|
|
|
VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?)",
|
|
VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?)",
|