Hi,
I'm trying to paste <script> var foo = 'foo' </script> into a Tiny-MCE Editor field (Silverstripe 3.1.).
I know this isn't best practice, but I need a quickndirty solution for this specific problem.
I've tried a lot, e.g. to overwrite valid_elements:
HtmlEditorConfig::get('cms')->setOption('extended_valid_elements', "*- ");
HtmlEditorConfig::get('cms')->setOption('verify_html', 'false'); // turn off html validation
This works and script-tags left in HTML-Code (results into: <script type="text/javascript">// <![CDATA[ var foo = 'foo'; // ]]></script>), but after "Save & publish" all <script></script> is gone and "cleaned" somehow (by the way, same result for <style>).
Could someone give me a hint, what cleaning-method is used here?
Thanks in advance
boo