Uploaded image for project: 'Plugins'
  1. Plugins
  2. CONTRIB-1726

OU wiki: Long page names cause database insert errors

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 1.9.7
    • Fix Version/s: None
    • Component/s: None
    • Labels:
    • Affected Branches:
      MOODLE_19_STABLE

      Description

      If you create a wiki page containing a link to a very long page name, such as

      [[This is a really long page name. It goes on and on and on and on. In fact it's not so much a name as a paragraph. I just want to keep typing! Forever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever!]]

      then this causes database errors because the name is more than 255 characters long.

      My proposed solution is to limit page name length to 200 characters; if you specify a longer link (such as the above) then only the first 200 characters will actually be a link. I might be nice and make it cut off at word boundary a la shorten_text, not sure.

        Attachments

          Activity

            People

            Assignee:
            quen Sam Marshall
            Reporter:
            quen Sam Marshall
            Participants:
            Component watchers:
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: