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

htmlAREA - uses the innerHTML property to delete child nodes from a parent.

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 1.8
    • Fix Version/s: 1.8.1
    • Component/s: Libraries
    • Labels:
      None
    • Affected Branches:
      MOODLE_18_STABLE
    • Fixed Branches:
      MOODLE_18_STABLE

      Description

      On line 1165 of htmlArea.php, htmlarea uses the innerHTML property to remove all the child nodes from the status bar. This can cause a run time error in Internet Explorer 7 in some contexts.

      Will commit the following fix to HEAD shortly -

      1165 this._statusBarTree.innerHTML = HTMLArea.I18N.msg["Path"] + ": ";

      replaced by
      while(this._statusBarTree.childNodes.length>0)

      { this._statusBarTree.removeChild(this._statusBarTree.childNodes[0]); }

      this._statusBarTree.appendChild(document.createTextNode(HTMLArea.I18N.msg["Path"] + ": "));

        Gliffy Diagrams

          Attachments

            Activity

            Hide
            aforth aforth added a comment -

            Line number is now 1143 not 1165

            Show
            aforth aforth added a comment - Line number is now 1143 not 1165
            Hide
            dougiamas Martin Dougiamas added a comment -

            Thanks, Anthony.

            Petr can you just do a quick check to make sure this doesn't break anything else and check in?

            Show
            dougiamas Martin Dougiamas added a comment - Thanks, Anthony. Petr can you just do a quick check to make sure this doesn't break anything else and check in?
            Hide
            aforth aforth added a comment -

            Found a further instance of this bug on line 877. Have committed a fix to head.

            Show
            aforth aforth added a comment - Found a further instance of this bug on line 877. Have committed a fix to head.

              People

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

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Fix Release Date:
                  11/Jun/07