通过使用浏览器对象模型,输出当前浏览器窗口中打开的文档的URL信息,并将显示在窗口中。

<script type="text/javascript">
window.document.write("这个网页文件来自:".bold());
window.document.write(window.location.toString());
</script>

原文地址:https://www.cnblogs.com/clear93/p/4624174.html