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

Copying and pasting video in rich text editing mode loses source tag, results in blank video

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Open
    • Priority: Minor
    • Resolution: Unresolved
    • Affects Version/s: 3.1.16, 3.2 regressions, 3.4.5, 3.5.5, 3.6, 3.7
    • Fix Version/s: None
    • Component/s: HTML Editor (Atto)
    • Labels:
    • Affected Branches:
      MOODLE_31_STABLE, MOODLE_34_STABLE, MOODLE_35_STABLE, MOODLE_36_STABLE, MOODLE_37_STABLE

      Description

      When you copy a video and paste it again in the rich text editor, you lose the source tag,
      eg. This:

      <video controls="true" width="800" height="600"><source src="https://youtu.be/sajCKwxXG_g">https://youtu.be/sajCKwxXG_g</video>
      

      becomes this:

      <video controls="true" width="800" height="600">https://youtu.be/sajCKwxXG_g</video>

      Which results in a blank video, which displays on the page but can't be viewed. We should expect the video to be copied correctly, with the source tag.

      Steps to reproduce:

      1. go to any page with html embedded that can be edited with atto, that has a youtube video link.
      2. go into the rich text editor for this page.
      3. copy and paste the video in the rich text editor.
      4. save, and go back to the page. You will see the video player, but it is blank with no source.
      5. check and see the source tag is gone from the html.

      I also found the same kind of problem when in the rich text editor, and you have your insertion point right after the video and hit enter. You will get a new video without a source tag too.

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              kristianr Kristian Ringer
              Participants:
              Component watchers:
              Andrew Nicols, Mathew May, Michael Hawkins, Shamim Rezaie, Simey Lameze
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:

                Time Tracking

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 10 minutes
                10m