为什么设置按钮点击之后没有反应呢
<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>location</title>
</head>
<script type="text/javascript">
function location(){
document.write(window.location.href);
}
</script>
<body>
<form>
<input type="button" value="点击获取输出显示文档的URL" onclick="location()">
</form>
</body>
</html>