Skip to content

Commit d3a1e12

Browse files
authored
Update post.php
Fixed the notification links. The thread URL and post URLs were the same. The thread URL was not pointing at the thread ID. The Post URL did not have the #forumpost added to it, so it would never scroll the screen down to the actual post.
1 parent 82b056f commit d3a1e12

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

post.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -328,8 +328,8 @@
328328
if (!empty($isnew) && $approved && !empty($GLOBALS['xoopsModuleConfig']['notification_enabled'])) {
329329
$tags = [];
330330
$tags['THREAD_NAME'] = Request::getString('subject', '', 'POST');
331-
$tags['THREAD_URL'] = XOOPS_URL . '/modules/' . $xoopsModule->getVar('dirname', 'n') . '/viewtopic.php?post_id=' . $postid;
332-
$tags['POST_URL'] = $tags['THREAD_URL']; // . '#forumpost' . $postid;
331+
$tags['THREAD_URL'] = XOOPS_URL . '/modules/' . $xoopsModule->getVar('dirname', 'n') . '/viewtopic.php?topic_id=' . $topicObject->getVar('topic_id');
332+
$tags['POST_URL'] = XOOPS_URL . '/modules/' . $xoopsModule->getVar('dirname', 'n') . '/viewtopic.php?post_id=' . $postid . '#forumpost' . $postid;
333333
require_once __DIR__ . '/include/notification.inc.php';
334334
$forum_info = newbb_notify_iteminfo('forum', $forumObject->getVar('forum_id'));
335335
$tags['FORUM_NAME'] = $forum_info['name'];

0 commit comments

Comments
 (0)