More 27395, very minor tweak: strip out body tags with attributes, and format the source shown. r=cmanske

This commit is contained in:
akkana%netscape.com 2000-02-16 00:12:31 +00:00
parent 24868a22e8
commit 9b9b3a5dc8

View File

@ -46,9 +46,8 @@ function Startup()
dump("Not all dialog controls were found!!!\n");
}
selection = editorShell.GetContentsAs("text/html", 1);
selection = (selection.replace(/<body>/,"")).replace(/<\/body>/,"");
//dump("Got selection: '" + selection + "'\n");
selection = editorShell.GetContentsAs("text/html", 35);
selection = (selection.replace(/<body[^>]*>/,"")).replace(/<\/body>/,"");
if (selection != "")
dialog.srcInput.value = selection;