diff options
Diffstat (limited to 'files/fr/web/api/document/images')
| -rw-r--r-- | files/fr/web/api/document/images/index.md | 33 |
1 files changed, 18 insertions, 15 deletions
diff --git a/files/fr/web/api/document/images/index.md b/files/fr/web/api/document/images/index.md index 1b127eb980..2aaeb008e4 100644 --- a/files/fr/web/api/document/images/index.md +++ b/files/fr/web/api/document/images/index.md @@ -5,29 +5,32 @@ tags: - Référence_du_DOM_Gecko translation_of: Web/API/Document/images --- -<p>{{ ApiRef() }}</p> +{{ ApiRef() }} -<p><code>document.images</code> renvoie une collection des images du document HTML courant.</p> +`document.images` renvoie une collection des images du document HTML courant. -<h2 id="Syntaxe">Syntaxe</h2> +## Syntaxe -<pre class="brush: js">HTMLCollection =document.images</pre> +```js +HTMLCollection =document.images +``` -<h2 id="Exemple">Exemple</h2> +## Exemple -<pre class="brush:js">var listeimg = document.images; -for(var i = 0; i < listeimg.length; i++) { +```js +var listeimg = document.images; +for(var i = 0; i < listeimg.length; i++) { if(listeimg[i] == "banner.gif") { // l'image banner a été trouvée } } -</pre> +``` -<h2 id="Notes">Notes</h2> +## Notes -<p><a href="/fr/DOM/document.images"><code>document.images</code></a> fait partie du DOM HTML, et fonctionne uniquement pour les document HTML.</p> -<h2 id="Sp.C3.A9cification">Spécification</h2> -<ul> - <li>Spécification DOM Level 2 HTML : <a href="http://www.w3.org/TR/DOM-Level-2-HTML/html.html#ID-90379117">HTMLDocument.images</a></li> - <li>Traduction en français (non normative) : <a href="http://www.yoyodesign.org/doc/w3c/dom2/html/html.html#ID-90379117">HTMLDocument.images</a></li> -</ul> +[`document.images`](/fr/DOM/document.images) fait partie du DOM HTML, et fonctionne uniquement pour les document HTML. + +## Spécification + +- Spécification DOM Level 2 HTML : [HTMLDocument.images](http://www.w3.org/TR/DOM-Level-2-HTML/html.html#ID-90379117) +- Traduction en français (non normative) : [HTMLDocument.images](http://www.yoyodesign.org/doc/w3c/dom2/html/html.html#ID-90379117) |
