location.href
URL (URI) を返します。
構文
location.href
例文
<html>
<head>
<title>location.href</title>
<script type="text/javascript"><!--
window.onload = function () {
document.getElementById("result").innerHTML = location.href;
}
// --></script>
</head>
<body>
<div id="result"></div>
</body>
</html>
関連記事
- location.search
- location.replace
- location.reload
- location.protocol
- location.port
- location.pathname
- location.hostname
- location.host
- location.hash
- location.assign
スポンサーリンク





