allow Sanitize to perform <script> tag sanitization

This PR contains the following changes:

* rely on Sanitize's script sanitization rather than the (broken) regexp based one
* minor syntax tidying