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

Linking multiple elements (eg. image + text) im htmleditor causes broken link to moodle.org

XMLWordPrintable

    • MOODLE_19_STABLE

      My colleague Mark Drechsler has demonstrated this bug in a video here: http://www.screencast.com/t/V0jYD7Bs7Y

      To summarise: if the HTML editor has some content like this:

      <a href="http://www.google.com/">Top Text</a><br />
      <a href="http://www.myimagelink.com/"><img src="blah.gif"></a><br />
      <a href="http://www.someothersite.com/">Footer text</a><br />

      If I save this (eg. as a label resource), everything is fine.

      THEN, edit the label again, highlight all the content (text + image) and then click the 'create link' button and set a URL, eg. http://www.example.com/

      Save the label and now go view it.

      The top text will link to http://www.example.org/

      The image + the text at the bottom will link to a URL like this: http://www.moodle.org/0.10390975221110266

      I've attached a small patch to the htmlview javascript which fixes this.

      Cheers

            moodle.com Moodle HQ
            ashleyholman Ashley Holman (Inactive)
            Votes:
            2 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:

                Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.