I have some PDF files that have been added to the library, however I am unable to add them. Instead, I get the error in the attached screen shot. The first error occurs when the form shown is loaded. The next ones occur each time "Submit" is attempted to be clicked.

I'll be happy to provide more info if needed, just let me know what you need.

Thanks in advance.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

askibinski’s picture

I can confirm this in 2.x-dev with the same javascript errors.

Dave Reid’s picture

Component: Media Browser » WYSIWYG integration
TechNikh’s picture

FileSize
56.74 KB

I am getting similar javascript errors

60event.layerX and event.layerY are broken and deprecated in WebKit. They will be removed from the engine in the near future.
media.format_form.js:26Uncaught TypeError: Cannot read property 'autosubmit' of undefined
Drupal.behaviors.mediaFormatForm.attachmedia.format_form.js:26
Drupal.attachBehaviorsdrupal.js:55
b.extend.eachjquery.js:33
Drupal.attachBehaviorsdrupal.js:53
Drupal.theme.placeholderdrupal.js:391
b.extend.readyjquery.js:30
ujquery.js:38
18event.layerX and event.layerY are broken and deprecated in WebKit. They will be removed from the engine in the near future.
wysiwyg-media.js:195Uncaught TypeError: Cannot read property 'attributes' of undefined
Drupal.wysiwyg.plugins.media.createTagwysiwyg-media.js:195
Drupal.wysiwyg.plugins.media.insertMediaFilewysiwyg-media.js:62
Drupal.wysiwyg.plugins.media.mediaBrowserOnSelectwysiwyg-media.js:42
Drupal.media.popups.mediaStyleSelector.dialogOptions.buttons.(anonymous function)media.popups.js:182
(anonymous function)/misc/ui/jquery.ui.dialog.min.js?v=1.8.7:29
c.event.handlejquery.js:64
c.event.add.h.handle.ojquery.js:57
Drupal.media.formatForm.submitmedia.format_form.js:49
c.event.handlejquery.js:64
c.event.add.h.handle.ojquery.js:57
24event.layerX and event.layerY are broken and deprecated in WebKit. They will be removed from the engine in the near future.
deggertsen’s picture

FileSize
74.72 KB

Seems like it's not just pdfs. I have a similar if not the same problem with audio files. See screenshot.

This issue basically renders this module useless to me.

Steven Jones’s picture

Yeah, so this appears to be because an image doesn't get inserted for these elements or somesuch, so for example, I have it set up so that my audio files are rendered in an audio player, but that doesn't return an image, so the wysiwyg chokes. If I add a file display mode that is an image, then it seems to work.

Steven Jones’s picture

Right, it would seem that formatters need to be aware that media module can only embed images, and take action accordingly, I'm going to open an issue with mediaelement (where I have the issue at the moment).

Steven Jones’s picture

Devin Carlson’s picture

Status: Active » Closed (duplicate)