WordPress.org

Make WordPress Core

Opened 4 years ago

Closed 4 years ago

Last modified 3 years ago

#11234 closed defect (bug) (invalid)

Image cut and paste breaks image

Reported by: caesarsgrunt Owned by:
Milestone: Priority: normal
Severity: normal Version: 2.8
Component: Editor Keywords:
Focuses: Cc:

Description

When cutting and pasting images in the rich editor, the image src and the link href are both changed from absolute links to relative links, resulting in a broken image in the post.

The image still shows fine in the admin (the new url is relative to wp-admin) but it doesn't work on the article page itself.

Additionally, the alignment class is lost when cutting and pasting the image.

Change History (3)

comment:1 azaozz4 years ago

  • Resolution set to invalid
  • Status changed from new to closed

This depends entirely on the browser. FF changes the src, Safari and IE seem to keep it the same. The same happens when you copy/paste a link from another browser tab/window. In addition FF won't let you access the clipboard from JS (security feature) so not much we can do to fix it.

Best is to report this on FF's bugtracker.

comment:2 nacin4 years ago

  • Milestone Unassigned deleted

comment:3 janfabry3 years ago

There was a change in 2.8 that removes the class attribute when pasting images. It works in the same browser in 2.7, and it works in a base installation of TinyMCE, so I assume it is something in WordPress. I will investigate this further and then maybe open a new ticket on it - unless this has been reported somewhere else?

Note: See TracTickets for help on using tickets.