I am getting Uncaught SyntaxError: Unexpected token ; at THE LINE NUMBER
Uncaught SyntaxError: Unexpected token ;
THE LINE NUMBER
// HTML Helper var documentHtml = function(html){
Try to change:
.replace(/(html|head|body|title|meta|script)>/gi,'
to:
.replace(/<\/(html|head|body|title|meta|script)>/gi,'<\/div>')
You need to escape / with \ in Javascript
/
\