aboutsummaryrefslogtreecommitdiff
path: root/files/fr/web/api/document/url/index.md
blob: d77a3890b94cc166023f64fe1535a9a6fb674926 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
---
title: Document.URL
slug: Web/API/Document/URL
translation_of: Web/API/Document/URL
---
{{APIRef("DOM")}}

Retourne l'**`URL`** du {{domxref("Document")}} sous forme de string (lecture seule).

## Syntaxe

```js
var string = document.URL
```

## Exemple

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

## Specification

- [DOM Level 2 HTML: URL](http://www.w3.org/TR/DOM-Level-2-HTML/html.html#ID-46183437)