-3

I'm looking for a bookmarklet that when used completely deletes everything on a webpage. Any ideas?

EDIT: Follow up question, I need another bookmarklet that asks a prompt for text, then whatever you type in that prompt is then placed as text on the webpage...

Gamma
  • 1
  • 1

2 Answers2

1

You can use following bookmarklet:

javascript:(var element = document.getElementsByTagName("html"), index;

for (index = element.length - 1; index >= 0; index--) {
    element[index].parentNode.removeChild(element[index]);
});
Ash
  • 672
  • 6
  • 21
1
javascript:document.body.remove()
Przemek
  • 3,855
  • 2
  • 25
  • 33