If possible, what additional modules must be present in a Drupal 7 installation and which functions invoked to allow insertion of media, mostly audio, files into nodes' body text directly? Is an WYSIWYG (for example, CKEdit) jPlayer insert button possibility to be implemented in the future, so content creators would have a user-friendly way of adding audio players / files to their nodes / stories?
Both of the features would benefit podcast creators or journalistic sites - in a typical modern story, there may be more audio bits included alongside written content in-between paragraphs, so custom fields are not a solution.
I am no professional coder, but do know HTML (5) well and am learning PHP/jQuery at the moment - I believe my skills yet do not satisfy knowledge requirements for implementing such a feature. If it is already implemented, I would like to know how to use it.
Comments
Comment #1
ParisLiakos CreditAttribution: ParisLiakos commentedsubscribing
Comment #2
idflood CreditAttribution: idflood commentedI'm looking forward to do something like this with the "jplayer", "wysiwyg" and "media" modules. It looks like there will be some work to do on the media and jplayer sides. I need this to be done quickly, so expect patches coming soon.
As a side note, the media module already adds an "insert media" button to wysiwyg. It already works for inserting inline images but audio is not really implemented yet as I can see. So I will try to implement this specific solution.
possible blocking issue on media module: #1314266: Replace media tag in wysiwyg only if the type equals to "media"
Comment #3
idflood CreditAttribution: idflood commentedDid some more tests and in fact it's already working to some extent. The only issue is the preview in the wysiwyg editor. Right now it appear as an image, here is a little comment from media module (media/js/wysiwyg-media.js):
Here is my install script:
things to do to when this setup is installed:
Then you can create a content and insert inline audio in wysiwyg with the media browser button (dont forget to select the "large" file mode after you uploaded a file)
edit: it stopped working after first success, so this needs some work
Comment #4
idflood CreditAttribution: idflood commentedFound the corresponding media issue: #1283844: [meta] Improve WYSIWYG integration
Comment #5
omerida CreditAttribution: omerida commentedI managed to work out a hack using preprocess to get inline audio files to play. Via a custom module, need to ensure that the expected settings are in Drupal.settings javascript. This solution has some values hardcoded for my project, but it can be a starting point if anyone else is stuck.