Problem/Motivation
I have Media 2.2 using the CKEditor CDN with the required plugins for media_ckeditor added locally.
I can insert an image into my body content and save it all okay - the image is rendered and alignment options respected.
When I come to edit the node (revisions enabled and Workbench moderation on) if I right click the image and try to select 'Media settings' I am directed to a 404 screen which the url /media/undefined/format-form
cannot be found. Double clicking gives me the image options but I cannot get back to the Media settings window. Clicking the image then re-clicking the media button goes to 404 page.
Comment | File | Size | Author |
---|---|---|---|
#3 | media-whitelist_regression_fields_undefined-2878763-3.patch | 305 bytes | joseph.olstad |
|
Comments
Comment #2
Andy_D CreditAttribution: Andy_D at Investis Digital commentedException faults are
JS Error appears on line 23:
if (jQuery(data.node).is('[data-media-element]')) {
DOMException: Failed to execute 'querySelectorAll' on 'Element': '*, :x'
Console error is:
GET (sitename)/media/undefined/format-form?render=media-popup&fields=undefined 404 (Not Found)
Comment #3
joseph.olstadmoving this to 'media' queue
clues in bold:
(sitename)/media/undefined/format-form?render=media-popup&fields=undefined
attached is a patch for the media module
Comment #4
joseph.olstadComment #5
joseph.olstadPlease test the patch out and get back to us. (apply it to the media module)
either way, let us know if this helps.
Comment #6
joseph.olstad@Andy_D , did the attached patch help you?
Comment #7
Andy_D CreditAttribution: Andy_D at Investis Digital commented@joseph.olstad - thanks for responding so quickly!
I reviewed my setup and found out that the CDN enabled version of CKEditor does not reference locally installed plugins. I therefore downloaded the full CKEditor package, added the suggested plugins and it all started working. Probably a good idea to have this patch anyway in case someone else gets in a similar pickle!
Thanks again.
Comment #8
joseph.olstadhmm, ok makes sense, whenever in doubt, use the recipe
https://www.drupal.org/node/2843391
as for the patch, I haven't tested the patch, not sure if it'll help that situation.
I think the correct solution is to install the plugins and ckeditor library locallly as you have done. However, if there's a better way, let us know.
Comment #9
joseph.olstadsupport issue appears to be resolved. Not sure if we need that patch
Comment #11
Andy_D CreditAttribution: Andy_D at Investis Digital commentedHappy to mark this fixed - with the proviso that you cannot use CDN hosted CKEditor!