Commit da886baa authored by Chris Graham's avatar Chris Graham
Browse files

Fixed MANTIS-4455 (Don't try to redirect to forum if no access)

parent 512e2765
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -146,7 +146,7 @@ SESSION_EXPIRY_TIME=Session expiry-time
SHOW_INLINE_STATS=Reveal usage figures
CONFIG_OPTION_show_inline_stats=Whether to show figures on various areas of your website that indicate how often those areas have been used.
STRONG_FORUM_TIE=Strongly tie content to the forum
CONFIG_OPTION_is_on_strong_forum_tie=When this is unticked (unchecked) forum comment topics are created when the first comment is added. When this is ticked (checked) forum comment topics are created as soon as content is added (so that the forum can be monitored to see what new content is added), and also posting a comment directs to view the forum topic.
CONFIG_OPTION_is_on_strong_forum_tie=When this is unticked (unchecked) forum comment topics are created when the first comment is added. When this is ticked (checked) forum comment topics are created as soon as content is added (so that the forum can be monitored to see what new content is added), and also posting a comment directs to view the forum topic (if you have access to the comments forum or aren't using the in-built forum).
WEBSTANDARDS_XHTML=Validate <abbr title="eXtensible Hypertext Markup Language">XHTML5</abbr>
WEBSTANDARDS_WCAG=Validate accessibility (<abbr title="Web Content Accessibility Guidelines">WCAG</abbr>)
WEBSTANDARDS_CSS=Validate <abbr title="Cascading Style Sheets">CSS</abbr>
+2 −2
Original line number Diff line number Diff line
@@ -868,13 +868,13 @@ function actualise_post_comment($allow_comments, $content_type, $content_id, $co
        $submitter
    );

    if (!is_null($topic_id)) {
    if (!is_integer($forum)) {
        $forum_id = $GLOBALS['FORUM_DRIVER']->forum_id_from_name($forum);
    } else {
        $forum_id = intval($forum);
    }

    if (!is_null($topic_id)) {
        if ((get_forum_type() == 'cns') && (!is_null($GLOBALS['LAST_POST_ID']))) {
            $extra_review_ratings = array();
            global $REVIEWS_STRUCTURE;
@@ -968,7 +968,7 @@ function actualise_post_comment($allow_comments, $content_type, $content_id, $co
        }
    }

    if (($post != '') && ($forum_tie) && (!$no_success_message)) {
    if (($post != '') && ($forum_tie) && (!$no_success_message) && ((get_forum_type() != 'cns') || (has_category_access(get_member(), 'forums', strval($forum_id))))) {
        require_code('site2');
        assign_refresh($GLOBALS['FORUM_DRIVER']->topic_url($GLOBALS['FORUM_DRIVER']->find_topic_id_for_topic_identifier($forum, $real_feedback_type . '_' . $content_id, do_lang('COMMENT')), $forum, true), 0.0);
    }