remove base and head tags in remove_script_and_style

This commit is contained in:
Anand Doshi 2015-04-05 21:31:43 +05:30
parent fac05f6f9e
commit 5f08c638c8

View file

@ -50,7 +50,7 @@ frappe.utils = {
remove_script_and_style: function(txt) {
if (!txt || (txt.indexOf("<script")===-1 && txt.indexOf("<style")===-1)) return txt;
return $("<div></div>").html(txt)
.find("script,noscript,style,title,meta").remove().end()
.find("script,noscript,style,title,meta,base,head").remove().end()
.html();
},
toggle_blockquote: function(txt) {