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.
Problem/Motivation
Often contrib modules need a way to indicate a settings textarea should never be WYSIWYG or have HTML code at all. This is very difficult to accomplish with BUEditor.
Proposed resolution
The de facto solution, implemented by the WYSIWYG module, is to support a #wysiwyg attribute on FAPI elements. If a textarea has #wysiwyg set to FALSE, then all editors should be suppressed on that element.
API changes
A simple check for #wysiwyg attribute in the _bueditor_textarea() function can bypass the editor for a specific field.
Original report by thePanz
Hi, will BUEditor support upcoming FAPI #wysiwyg setting?
Regards
Comment | File | Size | Author |
---|---|---|---|
#8 | wysiwyg-fapi-fix-327184-8.patch | 558 bytes | jstoller |
#2 | bueditor-pre_D7_FAPI_wysiwyg_fix.patch | 693 bytes | thePanz |
#1 | bueditor-pre_D7_FAPI_wysiwyg_fix.patch | 691 bytes | thePanz |
Comments
Comment #1
thePanz CreditAttribution: thePanz commentedThis patch implements this features...
I'm still asking myself if this module is still maintained anymore...
Comment #2
thePanz CreditAttribution: thePanz commentedRe-Rolled against latest -dev (February) release.
Comment #3
ufku CreditAttribution: ufku commentedthis won't go in because;
1- For 6.x there is no such api. It may be for 7.x
2- BUEditor is not a wysiwyg editor. There are usecases for plain-text fields where for example some characters not available on user's keyboard or some predefined phrases need to be inserted.
Comment #4
thePanz CreditAttribution: thePanz commentedHi, thank you for your reply.
1. I know that a some modules still use this feature in D6 (I don't remember if FCK or other editors still do that), so why don't do BUEditor?
2. You're right, so maybe BUEditor (for predefined phrases) will have to filter available buttons? I mean, inserting an IMG tag where the textarea is only for plain text isn't right..
Regards
Comment #5
Dave Reid@ufku: I'd really like you to re-consider this. A *LOT* of contrib modules are already using this as an easy way to indicate a settings textarea should never be WYSIWYG or have HTML code at all.
Comment #6
a_c_m CreditAttribution: a_c_m commentedSeems work is already ongoing : #429684: Add editor: BUEditor
Comment #7
ufku CreditAttribution: ufku commentedClosing 6.x-1.x issues as this branch is no more supported.
Comment #8
jstollerThis had me pulling my hair out for days. I'm bumping the request to version 6.x-2.x-dev and providing a patch for your consideration.
Comment #9
jstollerI updated the issue summery and title for clarity.
Comment #9.0
jstollerUpdate issue summery with template.