Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-7671

On "general" type forums, setting "open" to 0 doesn't prevent the "Reply" option to appear.

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Won't Fix
    • Icon: Minor Minor
    • 1.5.4
    • 1.5.4
    • Forum
    • None
    • MOODLE_15_STABLE
    • MOODLE_15_STABLE

      On "general" type forums, setting "open" to 0 doesn't prevent the "Reply" option to appear.

      This problem was detected when a forum had some postings and the teacher decided that the work should go on in some other place. So she set "open" to "0" but the Reply option still appeared. Of course, when students clicked on that link, a red box (in ENGLISH) appeared: "Sorry, but you can not post in this forum", so they could not really reply, even though Moodle said so.

      FIX:
      ===
      Simply check the "open" state before showing the "Reply" link.

      In discuss.php:
      Line 147: if(!$forum->open)

      { Line 148: $canreply = false; Line 149: }

      elseif ((empty($mygroupid) and $discussion->groupid == 1) || ($mygroupid == $discussion>groupid)) {
      ...

      Line 160: $canreply = ((empty($mygroupid) and $discussion->groupid == 1) || ($mygroupid == $discussion>groupid)) and $forum->open;
      ...

            lazyfish Yu Zhang
            petcheverry Pablo Etcheverry
            Votes:
            2 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:

                Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.