<html><head><title>caractères sélectionnés</title> <script type="text/javascript"><!-- function texteselectionne() { if (window.getSelection) alert(window.getSelection()); else if (document.getSelection) alert(document.getSelection()); else if (document.selection) alert(document.selection.createRange().text); } //--></script> </head><body> texte à sélectionner<br> texte à sélectionner<br><br> <textarea cols=80 rows=10> texte à sélectionner texte à sélectionner </textarea> <form> <input type="button" value="montrer" onclick="texteselectionne();"> </form> </body></html>