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
Родитель 7581b6bc06
Коммит 8145d06019
1 изменённых файлов: 2 добавлений и 3 удалений

Просмотреть файл

@ -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;