This issue started over at #1062948: Issue getting Media, Styles and WYSIWYG working together with MediaElement.js and relates to the MediaElement player, but requires a patch to Media's wysiwyg-media.js file to fix, so I'm creating this issue here.
In summary, if you are using the MediaElement module to display videos, the Media WYSIWYG browser fails to insert videos because MediaElement returns an <video> tag rather than <img>. At least, this is the behaviour I have experienced with CKEditor. The current implementation of the stripTags() function will remove everything that's not an image, so insertion fails.
The patch below causes the stripTags code to check for video tags as well as img, and thus allows you to insert inline video tags using the Media browser with CKEditor. CKEditor does not handle the video tags in a very stable fasion, but it works better than the JS errors that are currently thrown.
Unfortunately I don't have access to a Windows box right now, so it has only been tested in FF5.0 Mac and Chrome 12 Mac, both with just CKEditor. I have no idea how it will behave in other browsers, particularly IE.
| Comment | File | Size | Author |
|---|---|---|---|
| #1 | allow-inline-video-insertion-1210344.patch | 579 bytes | jrsinclair |
Comments
Comment #1
jrsinclair commentedThis is the patch.
Please note, this isn't intended as a fix for the issue, but a pointer in the right direction for anyone who wants to help out, or for people who are desperate to get something, anything working (like I am).
Comment #2
ZuluWarrior commentedSub,
I need to get this honoring the output filters supplied by media ideally, I would expect to set the formatting preset (Large, small, ect) and have it rendered by media (and hence via mediaelement) on node display (placeholder is fine in the wysiwyg).
This patch at least gets us started so I'm going to have a crack at this, but my javascripts not so good as my php.
Does anyone fancy having a crack at this with me over the next couple of days?
Comment #3
ZuluWarrior commentedin addition to the above, using the dev versions get's us a little closer, just some problems with the display formatters ect, I have stared a new issue here: http://drupal.org/node/1283844 and am gonna try and get involved in pushing this through to working :)
Comment #4
JacobSingh commentedComment #5
ParisLiakos commentedUnfortunately it doesnt works for audio :/
i added audio together with img and video,i can hit submit now but nothing happens:/nothing is added in the textarea
Comment #6
floeschie commented@JacobSingh: Why is this a duplicate? From which issue?
Comment #7
darksnowIt's a duplicate of the issue linked too in the first post.
For the record, I'm having this same problem with the audio tag.