window.location用法一:
<script language="javascript">
//获取域名
host = window.location.host;
host2=document.domain;
//获取页面完整地址
url = window.location.href;
document.write("<br>host="+host)
document.write("<br>host2="+host2)
document.write("<br>url="+url)
</script>
window.location用法二:
window.location.href("http://www.ie81.com"); //这个只能当前窗口打开,不能新窗口打开
window.open("http://www.ie81.com"); //新窗口打开