Ver Mensaje Individual
  #6 (permalink)  
Antiguo 14/07/2009, 01:29
GagleKas
 
Fecha de Ingreso: abril-2008
Mensajes: 141
Antigüedad: 16 años, 9 meses
Puntos: 0
Respuesta: Como se escribe con javascript en un textarea?

Algo haces mal porque con el value te tiene que funcionar.

Código html:
Ver original
  1.     <head>
  2.         <script type="text/javascript">
  3.             function texto (){
  4.                 document.getElementById ("t").value = "sfd";
  5.             }
  6.         </script>
  7.     </head>
  8.     <body>
  9.         <textarea id="t"></textarea>
  10.         <input type="button" value="clic" onclick="texto ();"/>
  11.     </body>
  12. </html>