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

blackboard 5 question import html entity and question name length safety [patch]

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 1.7
    • Fix Version/s: 1.7.1, 1.8
    • Component/s: Questions
    • Labels:
      None
    • Environment:
      Linux, PostgreSQL 7 backend
    • Database:
      PostgreSQL
    • Affected Branches:
      MOODLE_17_STABLE
    • Fixed Branches:
      MOODLE_17_STABLE, MOODLE_18_STABLE

      Description

      I was attempting to import questions using the blackboard 5 type that a faculty member was having problems with and the import was silently dying during the process. After turning on debugging I saw that the question->name field was simply too big >255 for the field in the database. I fixed that in the code by truncating the name to 254 characters. Also in this patch I check to see if the questions are already in HTML encoded format, and if so, I re-interpret the HTML entities so that things like ৻ are the actual character rather than code when printed to the screen. Attached is a test case and my patch.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                howardsmiller Howard Miller
                Reporter:
                paul.ortman Paul Ortman
                Tester:
                Nobody
                Participants:
                Component watchers:
                Tim Hunt, Andrew Nicols, Jun Pataleta, Michael Hawkins, Shamim Rezaie, Simey Lameze
              • Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Fix Release Date:
                  17/Jan/07