Visit Mozilla.org

DOM:document.URL

出典: MDC

« Gecko DOM リファレンス

目次

[編集] 概要

現在のドキュメントのURLを返します。

[編集] 構文

string = document.URL 

[編集]

var currentURL = document.URL; alert(currentURL);

[編集] 注意

URL は DOM Level 0 document.location.href プロパティからの代替です。 しかし、 document.URLdocument.location.href のように設定可能ではありません。

[編集] 仕様

DOM Level 2 HTML: URL