Update notes for submitted changes

* Move the HTML-escaping JavaScript code to a separate function