Moodle

Values of the course id and the user id in mdl_wiki_entries are zero.

Details

  • Type: Bug Bug
  • Status: Closed Closed
  • Priority: Major Major
  • Resolution: Won't Fix
  • Affects Version/s: 1.9.5
  • Fix Version/s: None
  • Component/s: Wiki (1.x)
  • Labels:
    None
  • Affected Branches:
    MOODLE_19_STABLE

Description

Please see mdl_wiki_entries table, the most of columns courseid and userid are zero!

The cause of this problem is in function wiki_add_entry(), mod/wiki/lib.php.

When the type of wiki (=wtype) is 'group' (teachers and students can edit the wiki), $wiki_entry->course and $wiki_entry->userid aren't set values.

I had attached a zip file which includes original code, modified code and commented code of function wiki_add_entry().

Please see and check, then try this.


mdl_wiki_entries are checked in global search for access control.

Activity

Hide
Tatsuya Shirai added a comment -

I think, upgrading of database to correct 'mdl_wiki_entries' will be needed.
The courseid can be corrected from 'mdl_wiki' easily, on the other hand, correcting the userid filed is not so easy (but may be it is not impossible), for example 'mdl_course_module' ?

Show
Tatsuya Shirai added a comment - I think, upgrading of database to correct 'mdl_wiki_entries' will be needed. The courseid can be corrected from 'mdl_wiki' easily, on the other hand, correcting the userid filed is not so easy (but may be it is not impossible), for example 'mdl_course_module' ?
Hide
Michael de Raadt added a comment -

Thanks for reporting this issue.

We have detected that this issue has been inactive for over a year has been recorded as affecting versions that are no longer supported.

If you believe that this issue is still relevant to current versions (2.1 and beyond), please comment on the issue. Issues left inactive for a further month will be closed.

Michael d;

lqjjLKA0p6

Show
Michael de Raadt added a comment - Thanks for reporting this issue. We have detected that this issue has been inactive for over a year has been recorded as affecting versions that are no longer supported. If you believe that this issue is still relevant to current versions (2.1 and beyond), please comment on the issue. Issues left inactive for a further month will be closed. Michael d; lqjjLKA0p6
Hide
Michael de Raadt added a comment -

I'm closing this issue as it appears to have become inactive and is probably not relevant to a current supported version. If you are encountering this problem or one similar, please launch a new issue.

Show
Michael de Raadt added a comment - I'm closing this issue as it appears to have become inactive and is probably not relevant to a current supported version. If you are encountering this problem or one similar, please launch a new issue.

People

Vote (0)
Watch (1)

Dates

  • Created:
    Updated:
    Resolved: