Executing a JavaScript file directly from the browser

前端 未结 6 1115
攒了一身酷
攒了一身酷 2021-01-31 04:31

This sounds like a trivia question but I really need to know.

If you put the URL of an HTML file in the Location bar of your browser, it will render that HTML. That\'s

6条回答
  •  南笙
    南笙 (楼主)
    2021-01-31 05:10

    In the address bar, you simply write

    javascript:/some javascript code here/;void(0);

    http://www.javascriptkata.com/2007/05/01/execute-javascript-code-directly-in-your-browser/

提交回复
热议问题