Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Is there any way to provide an option on how the code gets inserted into the text field when using the WYSIWYG editor button?
I like the connivence of the button, but I don't like how inserts html and styles the image and the caption within the editor.
I would like the WYSIWYG button to simply insert the code [caption caption="Here is some text" align="left"][/caption] around the image/media.
I also seem to be having trouble when disabling the wysiwyg button it leaves the caption html instead of the caption shortcode.
Thanks for any help you can provide.
Comments
Comment #1
gmclelland CreditAttribution: gmclelland commentedThis would be solved with https://drupal.org/node/696734#comment-7948853
Comment #2
kmontyWhile this is something that can be accomplished (as you note), I fail to see the real benefit of doing it (especially because most users will not be manually editing the HTML of the textfield. As you can see in the database, the caption is still stored as shortcode, not rendered HTML.
I'd accept a patch for this feature request, but I don't see the value in working on it (personally).