Moodle
  1. Moodle
  2. MDL-6701

"Course Module ID incorrect" error on any Administration operation

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.6.2
    • Fix Version/s: 1.6.6, 1.7
    • Component/s: None
    • Labels:
      None
    • Environment:
       Linux, PHP 5.0.4, MySQL 4.1.20, Apache 2.0.54, Moodle latest 1.6.2+ (2006050521)
    • Affected Branches:
      MOODLE_16_STABLE
    • Fixed Branches:
      MOODLE_16_STABLE, MOODLE_17_STABLE
    • Rank:
      28242

      Description

      No administration operations (Set page flags, Remove pages, Strip pages, Revert, Check links) can be carried out, the response is always: Course Module ID was incorrect.
      I think this is because there is no </form> closing tag in the mod/wiki/*.html files. The admin.php page that just includes the *.html pages at the very end is then supplying wrong id to the form (I think).
      What worked in my case was to add the closing </form> tags to all the *.html files. I'm attaching a diff for someone else to implement and commit (if checked and confirmed).

        Activity

        Hide
        Sam Marshall added a comment -

        Using current 1.7 development tree, Firefox, and PostgreSQL 8.1 I was not able to reproduce this issue. I was able to set page flags without experiencing that error (although I must admit I have no idea what the flags actually do, but it seemed to work).

        Perhaps it has been fixed already on HEAD?

        I did see another bug though in that strip versions didn't seem to work (invalid query)... will look at that.

        Show
        Sam Marshall added a comment - Using current 1.7 development tree, Firefox, and PostgreSQL 8.1 I was not able to reproduce this issue. I was able to set page flags without experiencing that error (although I must admit I have no idea what the flags actually do, but it seemed to work). Perhaps it has been fixed already on HEAD? I did see another bug though in that strip versions didn't seem to work (invalid query)... will look at that.
        Hide
        Daniel Miksik added a comment -

        I think this is rather dependent on the PHP/Apache combinatio (have seen that before with some other module).
        Regardless of whether you experience the bug in your environment, I think the 1.7 development tree still misses the closing </form> tags, so the pages loaded after selecting an administration task are not valid HTML pages. That is why I think this should be fixed.

        Show
        Daniel Miksik added a comment - I think this is rather dependent on the PHP/Apache combinatio (have seen that before with some other module). Regardless of whether you experience the bug in your environment, I think the 1.7 development tree still misses the closing </form> tags, so the pages loaded after selecting an administration task are not valid HTML pages. That is why I think this should be fixed.
        Hide
        Sam Marshall added a comment -

        I looked at the code and you are correct. Your patch seemed right, so I've checked it in.

        None of this is valid XHTML still (i.e. it uses upper case all over) but I figure that is not the sort of thing we need to bother correcting since the new wiki is coming...

        Show
        Sam Marshall added a comment - I looked at the code and you are correct. Your patch seemed right, so I've checked it in. None of this is valid XHTML still (i.e. it uses upper case all over) but I figure that is not the sort of thing we need to bother correcting since the new wiki is coming...
        Hide
        Daniel Miksik added a comment -

        Thank you, Sam. As for the XHTML compliance, what you say was my thinking as well.

        Show
        Daniel Miksik added a comment - Thank you, Sam. As for the XHTML compliance, what you say was my thinking as well.
        Hide
        Ken Wilson added a comment -

        Confirmed closing </form> tags in mod/wiki/*.html files. Thanks. Now closed.

        Show
        Ken Wilson added a comment - Confirmed closing </form> tags in mod/wiki/*.html files. Thanks. Now closed.
        Hide
        Brett Hinton added a comment -

        Can this fix be checked into the 1.6.x branch as a bug fix. It resolved the issue with the wiki pages not allowing any administration functions and it would be nice to backport to those of us who can't upgrade past 1.6 yet because of server issues. It is a very minor patch (just adding a form closing tag that is missing) but fixes the wiki administration issue. Confirmed on my 1.6.5+ installation. Apache 2, PHP 5.0.4 and MySQL 5.0.24

        Show
        Brett Hinton added a comment - Can this fix be checked into the 1.6.x branch as a bug fix. It resolved the issue with the wiki pages not allowing any administration functions and it would be nice to backport to those of us who can't upgrade past 1.6 yet because of server issues. It is a very minor patch (just adding a form closing tag that is missing) but fixes the wiki administration issue. Confirmed on my 1.6.5+ installation. Apache 2, PHP 5.0.4 and MySQL 5.0.24
        Hide
        Sam Marshall added a comment -

        OK, the patch didn't apply to 1.6 (well not in my eclipse) so I did it manually in 1.6 branch. Please check it works if possible, as I didn't.

        (Wow, 3 versions back...!)

        Show
        Sam Marshall added a comment - OK, the patch didn't apply to 1.6 (well not in my eclipse) so I did it manually in 1.6 branch. Please check it works if possible, as I didn't. (Wow, 3 versions back...!)

          People

          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: