Interesting, thank you.
This indeed works as expected, but it raises a question: Will this approach have any deleterious effects if $field_value
includes non-wysiwyg
fields?
I ask this, because our templates assemble together the values of different fields (and field types), into a single payload that may (or may not) include wysiwyg
fields. And, of course, it would be better to use this technique once at the final render instead of every place in which a wysiwyg
is called, especially since we switch wysiwyg
availability on and off in some cases with conditional logic.
Related question: We need to be able to render shortcodes inserted into textarea
fields as well, but I don't see a note like the above in the textarea
docs. Is this technique expected to also work with textarea
fields?