aboutsummaryrefslogtreecommitdiff
path: root/files/fr/web/guide/html/editable_content/index.html
diff options
context:
space:
mode:
authorFlorian Merz <me@fiji-flo.de>2021-02-11 12:36:08 +0100
committerFlorian Merz <me@fiji-flo.de>2021-02-11 12:36:08 +0100
commit39f2114f9797eb51994966c6bb8ff1814c9a4da8 (patch)
tree66dbd9c921f56e440f8816ed29ac23682a1ac4ef /files/fr/web/guide/html/editable_content/index.html
parent8260a606c143e6b55a467edf017a56bdcd6cba7e (diff)
downloadtranslated-content-39f2114f9797eb51994966c6bb8ff1814c9a4da8.tar.gz
translated-content-39f2114f9797eb51994966c6bb8ff1814c9a4da8.tar.bz2
translated-content-39f2114f9797eb51994966c6bb8ff1814c9a4da8.zip
unslug fr: move
Diffstat (limited to 'files/fr/web/guide/html/editable_content/index.html')
-rw-r--r--files/fr/web/guide/html/editable_content/index.html36
1 files changed, 36 insertions, 0 deletions
diff --git a/files/fr/web/guide/html/editable_content/index.html b/files/fr/web/guide/html/editable_content/index.html
new file mode 100644
index 0000000000..01e1691ed1
--- /dev/null
+++ b/files/fr/web/guide/html/editable_content/index.html
@@ -0,0 +1,36 @@
+---
+title: Contenu éditable
+slug: Web/HTML/Contenu_editable
+translation_of: Web/Guide/HTML/Editable_content
+---
+<h2 id="Introduction">Introduction</h2>
+<p>Chaque élément du HTML5 peut être éditable. Cette fonctionnalité a été introduite longtemps auparavant mais a maintenant été standarisée avec <a class="external" href="http://www.whatwg.org/" title="http://www.whatwg.org/">WHATWG</a> (<a class="external" href="http://www.whatwg.org/specs/web-apps/current-work/multipage/editing.html#contenteditable" title="http://www.whatwg.org/specs/web-apps/current-work/multipage/editing.html#contenteditable">voir la spécification HTML actuelle</a>). Avec des gestionnaires d'événements JavaScript, vous pouvez transformer votre page Web en un éditeur de texte, complet et rapide.</p>
+<h2 id="Compatibilité">Compatibilité</h2>
+<p>Le contenu éditable est entièrement compatible avec les navigateurs actuels :</p>
+<ul>
+ <li>Firefox 3.5+</li>
+ <li>Chrome 6.0+</li>
+ <li>Internet Explorer 6.0+</li>
+ <li>Safari 3.2+</li>
+ <li>Opera 8+</li>
+ <li>iOS Safari 5.0+</li>
+ <li>Android Browser 3.0+</li>
+</ul>
+<p>Ce n'est pas encore supporté par Opera Mini et Opera Mobile.</p>
+<h2 id="Comment_ça_marche">Comment ça marche ?</h2>
+<p>Fixez l'attribut <code>contenteditable</code> à <code>true</code> dans votre élément HTML. Ça peut être fait dans quasiment tous les éléments HTML.</p>
+<h2 id="Exemples">Exemples</h2>
+<p>Un exemple simple :</p>
+<pre>&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+  &lt;body&gt;
+    &lt;div contenteditable="true"&gt;
+      Ce texte peut être édité par l'utilisateur.
+    &lt;/div&gt;
+  &lt;/body&gt;
+&lt;/html&gt; </pre>
+<p>Vous pouvez observer un exemple concret intégrant JavaScript utilisant LocalStorage <a class="external" href="http://html5demos.com/contenteditable" title="http://html5demos.com/contenteditable">ici</a>. Le code source est disponible <a href="http://html5demos.com/contenteditable#view-source" title="http://html5demos.com/contenteditable#view-source">ici</a>.</p>
+<h2 id="Voir_aussi">Voir aussi</h2>
+<p><a href="/fr/docs/Midas" title="en/Midas">Comment interagir avec le contenu </a>(style proche de l'ancienne API Internet Explorer) ou encore <a href="/fr/docs/Rich-Text_Editing_in_Mozilla" title="en/rich-text editing in mozilla">ici</a>.</p>
+<div>
+ {{ languages({ "ja": "ja/HTML/Content_Editable", "zh-cn": "zh-cn/HTML/Content_Editable" }) }}</div>