<!DOCTYPE html>
<html>
<body>
<script>
document.write(location.href)//输出当前页面完整URL
</script>
</body>
</html>
相对路径:
<!DOCTYPE html>
<html>
<body>
<script>
document.write(location.pathname)//返回当前URL的路径名
</script>
</body>
</html>
<head><!--如果两个文件在同一目录下-->
<script type="text/javascript" src="jtinymce-5.6.2.min.js"></script>
<!--如果js文件在js目录下-->
<script type="text/javascript" src="js/jtinymce-5.6.2.min.js"></script>
</head>