Hi,
I do not believe the Editor will keep the script tag for you because it is not something that you can edit. A possible workaround for this is to replace the script tag with some static HTML tags and then replace then back with the original script block when done editing. For example, you can replace the script tag with something like this:
Code: HTML/ASPX
<div
class="css_class_for_script"
id="some_id_that_represent_the_js"></div>
The key points at here are:
1. You would usually need a special CSS class for such html elements so that it displays differently inside the editor;
2. You need to uniquely mark this element so that you can replace this element with your original script contents when done editing. Obviously you need to save your original script contents somewhere;
Hope this helps.
Thanks